Skip to content

Commit

Permalink
FIX: Correct error in inbox when null task
Browse files Browse the repository at this point in the history
An error was being raised as a result of the task being null
when accessing the grade and quality star data.
  • Loading branch information
macite committed Nov 13, 2017
1 parent c011118 commit 374d3a5
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ angular.module('doubtfire.projects.states.dashboard.directives.task-dashboard.di
$scope.gradeNames = gradeService.grades

$scope.hasBeenGivenStars = (t) ->
t.quality_pts > 0 || _.includes(taskService.gradeableStatuses, t.status)
t? && (t.quality_pts > 0 || _.includes(taskService.gradeableStatuses, t.status))

$scope.hasBeenGraded = (t) ->
_.isNumber(t.grade)
t? && (_.isNumber(t.grade))
)

0 comments on commit 374d3a5

Please sign in to comment.