summaryrefslogtreecommitdiffstats
path: root/db/migrate
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2019-09-24 15:41:50 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2019-09-24 15:41:50 +0000
commite83313240f38dc222923821be057312d5924a966 (patch)
treecb72cced388a2cfcf6cb99b0844f8abec61e8105 /db/migrate
parent947fdf100da845f1ae12c6176a4ae7bb96e0c693 (diff)
downloadredmine-e83313240f38dc222923821be057312d5924a966.tar.gz
redmine-e83313240f38dc222923821be057312d5924a966.zip
code cleanup: rubocop: fix Rails/Presence in db/migrate/20110228000100_copy_repositories_log_encoding.rb
git-svn-id: http://svn.redmine.org/redmine/trunk@18519 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'db/migrate')
-rw-r--r--db/migrate/20110228000100_copy_repositories_log_encoding.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/db/migrate/20110228000100_copy_repositories_log_encoding.rb b/db/migrate/20110228000100_copy_repositories_log_encoding.rb
index df9c3dca5..1648bf725 100644
--- a/db/migrate/20110228000100_copy_repositories_log_encoding.rb
+++ b/db/migrate/20110228000100_copy_repositories_log_encoding.rb
@@ -1,7 +1,7 @@
class CopyRepositoriesLogEncoding < ActiveRecord::Migration[4.2]
def self.up
encoding = Setting.commit_logs_encoding.to_s.strip
- encoding = encoding.blank? ? 'UTF-8' : encoding
+ encoding = encoding.presence || 'UTF-8'
# encoding is NULL by default
Repository.where("type IN ('Bazaar', 'Cvs', 'Darcs')").
update_all(["log_encoding = ?", encoding])