aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnthony Ross <anthony.ross@getbraintree.com>2017-08-09 13:44:36 +0000
committerAnthony Ross <anthony.ross@getbraintree.com>2017-08-09 13:44:36 +0000
commitad41a27b8c29219350d0d5d39593e14cc8a04b71 (patch)
treee539d066a271e4647d6d5cee8cf41d2d87bbdb7f
parent4b72bee47bb590efac498ad2494efa769350aabd (diff)
downloadrails-ad41a27b8c29219350d0d5d39593e14cc8a04b71.tar.gz
rails-ad41a27b8c29219350d0d5d39593e14cc8a04b71.tar.bz2
rails-ad41a27b8c29219350d0d5d39593e14cc8a04b71.zip
Use copy to preserve file permissions
-rw-r--r--activerecord/lib/active_record/tasks/postgresql_database_tasks.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/tasks/postgresql_database_tasks.rb b/activerecord/lib/active_record/tasks/postgresql_database_tasks.rb
index a2e74efc2b..9d7249e1f9 100644
--- a/activerecord/lib/active_record/tasks/postgresql_database_tasks.rb
+++ b/activerecord/lib/active_record/tasks/postgresql_database_tasks.rb
@@ -136,7 +136,7 @@ module ActiveRecord
ensure
tempfile.close
end
- FileUtils.mv(tempfile.path, filename)
+ FileUtils.cp(tempfile.path, filename)
end
end
end