From 01c8df01ec0608f1f25b2f1444adabb98fa5ee8a Mon Sep 17 00:00:00 2001 From: Unknwon Date: Thu, 24 Oct 2019 01:51:46 -0700 Subject: internal: move packages under this directory (#5836) * Rename pkg -> internal * Rename routes -> route * Move route -> internal/route * Rename models -> db * Move db -> internal/db * Fix route2 -> route * Move cmd -> internal/cmd * Bump version --- models/migrations/v19.go | 18 ------------------ 1 file changed, 18 deletions(-) delete mode 100644 models/migrations/v19.go (limited to 'models/migrations/v19.go') diff --git a/models/migrations/v19.go b/models/migrations/v19.go deleted file mode 100644 index bae2e355..00000000 --- a/models/migrations/v19.go +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2018 The Gogs Authors. All rights reserved. -// Use of this source code is governed by a MIT-style -// license that can be found in the LICENSE file. - -package migrations - -import ( - "xorm.io/xorm" -) - -func cleanUnlinkedWebhookAndHookTasks(x *xorm.Engine) error { - _, err := x.Exec(`DELETE FROM webhook WHERE repo_id NOT IN (SELECT id FROM repository);`) - if err != nil { - return err - } - _, err = x.Exec(`DELETE FROM hook_task WHERE repo_id NOT IN (SELECT id FROM repository);`) - return err -} -- cgit v1.2.3