Skip to content

Commit ed37095

Browse files
author
Andrew Dang
committed
remove ActiveModel::Errors#get deprecation for Rails 5.1
1 parent b8b3cfd commit ed37095

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/judge/validation.rb

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ def validate!
3333
end
3434

3535
def as_json(options = {})
36-
record.errors.get(@attribute) || []
36+
record.errors[@attribute] || []
3737
end
3838
end
3939

@@ -51,4 +51,4 @@ def method_missing(*args)
5151
end
5252
end
5353

54-
end
54+
end

0 commit comments

Comments
 (0)