mirror of
https://github.com/HabitRPG/habitica.git
synced 2025-12-14 21:27:23 +01:00
WIP(teams): display assigned tasks on user's personal board
This commit is contained in:
@@ -355,10 +355,10 @@ api.taskNeedsWork = {
|
||||
if (['daily', 'todo'].indexOf(task.type) === -1) {
|
||||
throw new BadRequest('Cannot roll back use of Habits or Rewards.');
|
||||
}
|
||||
if (!task.group.assignedUsers || !task.group.assignedUsers[assignedUserId]) {
|
||||
if (!task.group.assignedUsersDetail || !task.group.assignedUsersDetail[assignedUserId]) {
|
||||
throw new BadRequest('User not assigned to this task.');
|
||||
}
|
||||
if (!task.group.assignedUsers[assignedUserId].completed) {
|
||||
if (!task.group.assignedUsersDetail[assignedUserId].completed) {
|
||||
throw new BadRequest('Task not completed by this user.');
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user