Class: Turkee::TurkeeStudy
- Inherits:
-
Object
- Object
- Turkee::TurkeeStudy
- Includes:
- Mongoid::Document, Mongoid::Timestamps
- Defined in:
- lib/models/turkee_study.rb
Constant Summary collapse
- GOLD_RESPONSE_INDEX =
3
Instance Method Summary collapse
Instance Method Details
#approve? ⇒ Boolean
12 13 14 15 |
# File 'lib/models/turkee_study.rb', line 12 def approve? words = feedback.split(/\W+/) gold_response.present? ? (gold_response == words[GOLD_RESPONSE_INDEX]) : true end |