From 8bdf173cb1d13cc9b1aec930f80ed64599eecdbc Mon Sep 17 00:00:00 2001 From: Jacob Fugal Date: Tue, 25 Aug 2015 15:52:54 -0600 Subject: [PATCH] use excused instead of excused? for AR-agnosticism and document the dependency refs CNVS-21654 Change-Id: I40056afb93cb1c1968cf5019d613d662b1aa9ad6 test-plan: N/A Reviewed-on: https://gerrit.instructure.com/61804 Tested-by: Jenkins Product-Review: Jacob Fugal QA-Review: Jacob Fugal Reviewed-by: Rob Orton --- app/models/submission.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/models/submission.rb b/app/models/submission.rb index a11c37d6a51..82109aac4b2 100644 --- a/app/models/submission.rb +++ b/app/models/submission.rb @@ -1058,6 +1058,7 @@ class Submission < ActiveRecord::Base # * cached_due_date (Time) # * submitted_at (Time) # * score (Fixnum) + # * excused (Boolean) # module Tardiness def past_due? @@ -1087,7 +1088,7 @@ class Submission < ActiveRecord::Base # QUESTIONS FOR ME: # * are we messing up graded / not graded counts??? def graded? - excused? || (!!score && workflow_state == 'graded') + excused || (!!score && workflow_state == 'graded') end end include Tardiness