Sha256: 984faf3d2181f8c20c5ae806a90906b4d8499f54995e329ce249f6ede693f676
Contents?: true
Size: 591 Bytes
Versions: 29
Compression:
Stored size: 591 Bytes
Contents
require "hackathon_manager/engine" module HackathonManager def self.reload_config(app) hackathon = app.config_for(:hackathon) # Applications without a specified config.time_zone will parse # this as a string instead of a Time if hackathon['last_day_to_apply'].is_a?(String) hackathon['last_day_to_apply'] = Time.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
Version data entries
29 entries across 29 versions & 1 rubygems