mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-06-18 01:14:37 -04:00
Replace deprecated Id method with ID (#2655)
This commit is contained in:
parent
e1266a19c8
commit
aa962deec0
31 changed files with 84 additions and 84 deletions
|
@ -173,7 +173,7 @@ Please try to upgrade to a lower version (>= v0.6.0) first, then upgrade to curr
|
|||
if int(v-minDBVersion) > len(migrations) {
|
||||
// User downgraded Gitea.
|
||||
currentVersion.Version = int64(len(migrations) + minDBVersion)
|
||||
_, err = x.Id(1).Update(currentVersion)
|
||||
_, err = x.ID(1).Update(currentVersion)
|
||||
return err
|
||||
}
|
||||
for i, m := range migrations[v-minDBVersion:] {
|
||||
|
@ -182,7 +182,7 @@ Please try to upgrade to a lower version (>= v0.6.0) first, then upgrade to curr
|
|||
return fmt.Errorf("do migrate: %v", err)
|
||||
}
|
||||
currentVersion.Version = v + int64(i) + 1
|
||||
if _, err = x.Id(1).Update(currentVersion); err != nil {
|
||||
if _, err = x.ID(1).Update(currentVersion); err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue