lib/hackathon_manager.rb in hackathon_manager-0.5.2 vs lib/hackathon_manager.rb in hackathon_manager-0.5.3
- old
+ new
@@ -10,6 +10,11 @@
hackathon['last_day_to_apply'] = DateTime.parse(hackathon['last_day_to_apply'])
end
app.config.hackathon = hackathon
end
+
+ def self.field_enabled?(field)
+ disabled_fields = Rails.configuration.hackathon['disabled_fields'] || []
+ !disabled_fields.include?(field.to_s)
+ end
end