Skip to content

Commit

Permalink
Normalize questions before validation
Browse files Browse the repository at this point in the history
  • Loading branch information
rwdaigle committed Jul 18, 2012
1 parent 9104ce5 commit 53ffd0f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/models/unit.rb
Expand Up @@ -7,7 +7,7 @@ class Unit < ActiveRecord::Base
validates_presence_of :question, :subject validates_presence_of :question, :subject
validates_uniqueness_of :question, :scope => :subject_id validates_uniqueness_of :question, :scope => :subject_id


before_save :normalize_question, :set_processor_type before_validation :normalize_question, :set_processor_type


belongs_to :subject belongs_to :subject
has_many :learnings, :dependent => :delete_all has_many :learnings, :dependent => :delete_all
Expand Down

0 comments on commit 53ffd0f

Please sign in to comment.