summaryrefslogtreecommitdiffstats
path: root/lib/redmine/ciphering.rb
diff options
context:
space:
mode:
authorGo MAEDA <maeda@farend.jp>2020-09-01 14:19:10 +0000
committerGo MAEDA <maeda@farend.jp>2020-09-01 14:19:10 +0000
commitd0c56c0f6afc5eb5fd20ee1e902acc31a33fbac9 (patch)
treecafc227db4ce2853ae092162db65cd3d1a3e2bc1 /lib/redmine/ciphering.rb
parentb0739821e81f439d6bc65b15245da68b9545192d (diff)
downloadredmine-d0c56c0f6afc5eb5fd20ee1e902acc31a33fbac9.tar.gz
redmine-d0c56c0f6afc5eb5fd20ee1e902acc31a33fbac9.zip
Rake tasks "db:encrypt" and "db:decrypt" may fail due to validation error (#33926).
Patch by Go MAEDA. git-svn-id: http://svn.redmine.org/redmine/trunk@19999 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'lib/redmine/ciphering.rb')
-rw-r--r--lib/redmine/ciphering.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/redmine/ciphering.rb b/lib/redmine/ciphering.rb
index d5ceb0c6c..469d3b9e6 100644
--- a/lib/redmine/ciphering.rb
+++ b/lib/redmine/ciphering.rb
@@ -74,7 +74,7 @@ module Redmine
all.each do |object|
clear = object.send(attribute)
object.send "#{attribute}=", clear
- raise(ActiveRecord::Rollback) unless object.save(:validation => false)
+ raise(ActiveRecord::Rollback) unless object.save(validate: false)
end
end ? true : false
end
@@ -84,7 +84,7 @@ module Redmine
all.each do |object|
clear = object.send(attribute)
object.send :write_attribute, attribute, clear
- raise(ActiveRecord::Rollback) unless object.save(:validation => false)
+ raise(ActiveRecord::Rollback) unless object.save(validate: false)
end
end ? true : false
end