Skip to content

mproctor13/sequel_validation_exceptions

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 

Repository files navigation

Installation:
1) install the gem
gem install sequel_validation_exceptions
2) specify the plugin in your sequel model
plugin :validation_exceptions

In a similar vein to the ActiveRecord ORM, this sequel plugin adds save!, update!, create!, and find_or_create! to the sequel model class. All of these methods will raise a Sequel::ValidationException if validation fails.

Examples:
account = Account.new :name => 'Mac'
account.save!

account.update! :name => 'Mac'

Account.create! :name => 'Mac'

Account.find_or_create! :name => 'Mac'



About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Ruby 100.0%