summaryrefslogtreecommitdiff
path: root/app/services
diff options
context:
space:
mode:
authorJames Lopez <james@jameslopez.es>2017-06-22 16:54:54 +0200
committerJames Lopez <james@jameslopez.es>2017-06-23 11:41:43 +0200
commite2e0b175ae43bef44ba5fdc45b4a719aaae83422 (patch)
tree8a578fa45ba5fbd5da456c1fd439f21220f5cec8 /app/services
parent12dc3992ea189452532587a2b30b8765c0f09381 (diff)
downloadgitlab-ce-e2e0b175ae43bef44ba5fdc45b4a719aaae83422.tar.gz
fix specs
Diffstat (limited to 'app/services')
-rw-r--r--app/services/users/update_service.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/services/users/update_service.rb b/app/services/users/update_service.rb
index 33f3686c8d5..36dcc69f8cf 100644
--- a/app/services/users/update_service.rb
+++ b/app/services/users/update_service.rb
@@ -10,7 +10,7 @@ module Users
def execute(skip_authorization: false, validate: true, &block)
assign_attributes(skip_authorization, &block)
- if @user.save(validate: validate) || @user.errors.empty?
+ if @user.save(validate: validate)
success
else
error(@user.errors.full_messages.uniq.join('. '))