not_naughty 0.4.1 → 0.4.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. data/Rakefile +1 -1
  2. data/lib/sequel_not_naughty.rb +4 -2
  3. metadata +1 -1
data/Rakefile CHANGED
@@ -9,7 +9,7 @@ include FileUtils
9
9
  # Configuration
10
10
  ##############################################################################
11
11
  NAME = "not_naughty"
12
- VERS = "0.4.1"
12
+ VERS = "0.4.2"
13
13
  CLEAN.include ["**/.*.sw?", "pkg/*", ".config", "doc/*", "coverage/*"]
14
14
  RDOC_OPTS = [
15
15
  "--quiet",
@@ -81,8 +81,10 @@ module Sequel #:nodoc:
81
81
  base.instance_eval do
82
82
  def_hook_method :before_validate
83
83
  def_hook_method :after_validate
84
- alias_method :validate_without_hooks, :validate
85
- alias_method :validate, :validate_with_hooks
84
+ unless instance_methods.include? 'validate_without_hooks'
85
+ alias_method :validate_without_hooks, :validate
86
+ alias_method :validate, :validate_with_hooks
87
+ end
86
88
  end
87
89
  end
88
90
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: not_naughty
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.1
4
+ version: 0.4.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - "Florian A\xC3\x9Fmann"