We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a677c08 commit 08066c7Copy full SHA for 08066c7
doc/guides/registration_field.rdoc
@@ -28,7 +28,7 @@ create account hook:
28
before_create_account do
29
# Validate the name field. This example checks that it is not empty,
30
# but you may want to have application specific checks.
31
- unless name = param("name").empty?
+ if name = param("name").empty?
32
throw_error_status(422, "name", "must be present")
33
end
34
@@ -54,7 +54,7 @@ You can then handle the new submitted field as follows:
54
55
56
# Validate the name field
57
- throw_error_status(422, "name", "must be present") unless param("name").empty?
+ throw_error_status(422, "name", "must be present") if param("name").empty?
58
59
60
after_create_account do
0 commit comments