Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis Reigel <mail@koffeinfrei.org>2017-09-04 12:45:17 +0300
committerAlexis Reigel <mail@koffeinfrei.org>2017-09-05 13:18:34 +0300
commit703b39d4405af553b142071634db006941272db6 (patch)
treeea83ff7967d56436abae45ba7ea223b564015f9a /db/post_migrate
parentc4bb09bdb80817b84b6fbbdbda75907125c0512d (diff)
truncate gpg signature instead of destroy
Diffstat (limited to 'db/post_migrate')
-rw-r--r--db/post_migrate/20170830084744_destroy_gpg_signatures.rb13
1 files changed, 1 insertions, 12 deletions
diff --git a/db/post_migrate/20170830084744_destroy_gpg_signatures.rb b/db/post_migrate/20170830084744_destroy_gpg_signatures.rb
index de2e7e79e86..b04d36f6537 100644
--- a/db/post_migrate/20170830084744_destroy_gpg_signatures.rb
+++ b/db/post_migrate/20170830084744_destroy_gpg_signatures.rb
@@ -1,19 +1,8 @@
class DestroyGpgSignatures < ActiveRecord::Migration
DOWNTIME = false
- include Gitlab::Database::MigrationHelpers
- disable_ddl_transaction!
-
- class GpgSignature < ActiveRecord::Base
- self.table_name = 'gpg_signatures'
-
- include EachBatch
- end
-
def up
- GpgSignature.each_batch do |relation|
- relation.delete_all
- end
+ truncate(:gpg_signatures)
end
def down