Skip to content

Commit

Permalink
Merge branch 'patch-1' of https://github.com/untoldone/mongomapper in…
Browse files Browse the repository at this point in the history
…to untoldone-patch-1
  • Loading branch information
jnunemaker committed Apr 16, 2012
2 parents 1a4cb8d + 096d351 commit 4822f86
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/mongo_mapper/exceptions.rb
Expand Up @@ -14,7 +14,10 @@ class NotSupported < Error; end

# raised when document not valid and using !
class DocumentNotValid < Error
attr_reader :document

def initialize(document)
@document = document
super("Validation failed: #{document.errors.full_messages.join(", ")}")
end
end
Expand Down

0 comments on commit 4822f86

Please sign in to comment.