Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Do not send nil to build (Datamapper compability)

  • Loading branch information...
commit d5049240e2a808acb509e9d639995e7f36e21776 1 parent 529cd8b
José Valim josevalim authored
Showing with 4 additions and 1 deletion.
  1. +3 −0  CHANGELOG.rdoc
  2. +1 −1  lib/devise/controllers/helpers.rb
3  CHANGELOG.rdoc
View
@@ -1,3 +1,6 @@
+* enhancements
+ * [#42] Do not send nil to build (DataMapper compatibility)
+
== 0.5.5
* enhancements
2  lib/devise/controllers/helpers.rb
View
@@ -59,7 +59,7 @@ def resource=(new_resource)
def build_resource
self.resource ||= begin
attributes = params[resource_name].try(:except, :password, :password_confirmation)
- resource_class.new(attributes)
+ resource_class.new(attributes || {})
end
end
Please sign in to comment.
Something went wrong with that request. Please try again.