From 21835855dbd9237b3050ab844f3f1550a877397a Mon Sep 17 00:00:00 2001 From: Marius BALTEANU Date: Tue, 30 Mar 2021 12:27:45 +0300 Subject: [PATCH 17/19] Fix "DEPRECATION WARNING: Calling '<<' to an ActiveModel::Errors message array in order to add an error is deprecated." (#29914, #34985). --- lib/redmine/sudo_mode.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/redmine/sudo_mode.rb b/lib/redmine/sudo_mode.rb index ca15705d6..9703f0c77 100644 --- a/lib/redmine/sudo_mode.rb +++ b/lib/redmine/sudo_mode.rb @@ -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 -- 2.22.0