Skip to content

Commit

Permalink
Keep consistency on allow_blank and allow_nil qualifiers
Browse files Browse the repository at this point in the history
After some discussion[1] was decided that these qualifiers do not accept
any parameter.

thoughtbot#722
  • Loading branch information
maurogeorge committed Sep 22, 2015
1 parent a3fb06c commit f2edde6
Showing 1 changed file with 4 additions and 4 deletions.
Expand Up @@ -302,13 +302,13 @@ def in_range(range)
self
end

def allow_blank(allow_blank = true)
@options[:allow_blank] = allow_blank
def allow_blank
@options[:allow_blank] = true
self
end

def allow_nil(allow_nil = true)
@options[:allow_nil] = allow_nil
def allow_nil
@options[:allow_nil] = true
self
end

Expand Down

0 comments on commit f2edde6

Please sign in to comment.