]> source.dussan.org Git - redmine.git/commitdiff
Fix "DEPRECATION WARNING: Calling '<<' to an ActiveModel::Errors message array in...
authorGo MAEDA <maeda@farend.jp>
Thu, 1 Apr 2021 15:41:07 +0000 (15:41 +0000)
committerGo MAEDA <maeda@farend.jp>
Thu, 1 Apr 2021 15:41:07 +0000 (15:41 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@20898 e93f8b46-1217-0410-a6f0-8f06a7374b81

lib/redmine/sudo_mode.rb

index ca15705d68e6b414140b548faeb3fd4e7ce60ffe..9703f0c775c3c8ae43c5f334b3eaf0916948267a 100644 (file)
@@ -20,7 +20,7 @@ module Redmine
 
       def check_password
         unless password.present? && User.current.check_password?(password)
-          errors[:password] << :invalid
+          errors.add(:password, :invalid)
         end
       end
     end