Sha256: 7fb2854b2fddb396d066583f83cdc712fb3fd5d7370a0d0f19eebda60444dafb
Contents?: true
Size: 652 Bytes
Versions: 1
Compression:
Stored size: 652 Bytes
Contents
class DisableFileTypes < ActiveRecord::Migration def self.up Radiant::Config['assets.skip_filetype_validation'] = true puts "-- Setting default content types in Radiant::Config" if defined? SettingsExtension && Radiant::Config.column_names.include?('description') Radiant::Config.find(:all).each do |c| description = case c.key when 'assets.skip_filetype_validations' 'When set to true, disables the filetype validations. Set to false to enable them.' else c.description end c.update_attribute :description, description end end end def self.down end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
radiant-paperclipped-extension-0.8.1 | db/migrate/20090316132151_disable_file_types.rb |