summaryrefslogtreecommitdiffstats
path: root/models/packages/package_file.go
diff options
context:
space:
mode:
Diffstat (limited to 'models/packages/package_file.go')
-rw-r--r--models/packages/package_file.go6
1 files changed, 3 insertions, 3 deletions
diff --git a/models/packages/package_file.go b/models/packages/package_file.go
index 6d0fd185a0..7f794836dc 100644
--- a/models/packages/package_file.go
+++ b/models/packages/package_file.go
@@ -5,13 +5,13 @@ package packages
import (
"context"
- "errors"
"strconv"
"strings"
"time"
"code.gitea.io/gitea/models/db"
"code.gitea.io/gitea/modules/timeutil"
+ "code.gitea.io/gitea/modules/util"
"xorm.io/builder"
)
@@ -22,9 +22,9 @@ func init() {
var (
// ErrDuplicatePackageFile indicates a duplicated package file error
- ErrDuplicatePackageFile = errors.New("Package file does exist already")
+ ErrDuplicatePackageFile = util.NewAlreadyExistErrorf("package file already exists")
// ErrPackageFileNotExist indicates a package file not exist error
- ErrPackageFileNotExist = errors.New("Package file does not exist")
+ ErrPackageFileNotExist = util.NewNotExistErrorf("package file does not exist")
)
// EmptyFileKey is a named constant for an empty file key