rails 4.0: fix enrollment_state recalculation
rails 4.0: fix enrollment_state recalculation

refs #CNVS-32350

Change-Id: If59ce86ff7ed5f2b6a54401890402a1b627149b3
Reviewed-on: https://gerrit.instructure.com/92863
Tested-by: Jenkins
Reviewed-by: Rob Orton <7e09c9d3e96378bf549fc283fd6e1e5b7014cc33@instructure.com>
Product-Review: James Williams  <3a5f4ed991dbfa5c9ef76ad729d240ca12f62180@instructure.com>
QA-Review: James Williams  <3a5f4ed991dbfa5c9ef76ad729d240ca12f62180@instructure.com>

instructure/canvas-lms,SwinburneOnline/canvas-lms,venturehive/canvas-lms,sfu/canvas-lms,venturehive/canvas-lms,HotChalk/canvas-lms,sfu/canvas-lms,djbender/canvas-lms,matematikk-mooc/canvas-lms,SwinburneOnline/canvas-lms,instructure/canvas-lms,SwinburneOnline/canvas-lms,venturehive/canvas-lms,grahamb/canvas-lms,grahamb/canvas-lms,HotChalk/canvas-lms,SwinburneOnline/canvas-lms,HotChalk/canvas-lms,matematikk-mooc/canvas-lms,sfu/canvas-lms,sfu/canvas-lms,venturehive/canvas-lms,sfu/canvas-lms,sfu/canvas-lms,grahamb/canvas-lms,grahamb/canvas-lms,instructure/canvas-lms,matematikk-mooc/canvas-lms,instructure/canvas-lms,HotChalk/canvas-lms,sfu/canvas-lms,instructure/canvas-lms,djbender/canvas-lms,instructure/canvas-lms,grahamb/canvas-lms,instructure/canvas-lms,djbender/canvas-lms,djbender/canvas-lms,matematikk-mooc/canvas-lms