Skip to content

Instantly share code, notes, and snippets.

@snusnu
Created June 2, 2009 22:46
Show Gist options
  • Save snusnu/122648 to your computer and use it in GitHub Desktop.
Save snusnu/122648 to your computer and use it in GitHub Desktop.
Merb::BootLoader.before_app_loads do
# This will get executed after dependencies have been loaded but before your app's classes have loaded.
Date.add_format(:tranzaction_date, '%m/%d/%y')
class ::DataMapper::Validate::ValidationErrors
def each
errors.map.each do |k, v|
next if v.blank?
yield(k, v)
end
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment