From 2cb83f13fd86f99a2c7a9d42461b58fb0a47cf44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E1=B4=9C=C9=B4=E1=B4=8B=C9=B4=E1=B4=A1=E1=B4=8F=C9=B4?= Date: Fri, 4 Sep 2020 05:56:31 +0800 Subject: [PATCH] repo: set default value for `is_unlisted` column (#6305) --- internal/db/repo.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/db/repo.go b/internal/db/repo.go index 6d1cb3d9d..2a887c7ff 100644 --- a/internal/db/repo.go +++ b/internal/db/repo.go @@ -173,10 +173,10 @@ type Repository struct { NumOpenMilestones int `xorm:"-" gorm:"-" json:"-"` NumTags int `xorm:"-" gorm:"-" json:"-"` - IsPrivate bool + IsPrivate bool // TODO: When migrate to GORM, make sure to do a loose migration with `HasColumn` and `AddColumn`, // see docs in https://gorm.io/docs/migration.html. - IsUnlisted bool + IsUnlisted bool `xorm:"NOT NULL DEFAULT false"` IsBare bool IsMirror bool