-
Notifications
You must be signed in to change notification settings - Fork 992
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'feat/1.1.1/state' into test
- Loading branch information
Showing
29 changed files
with
501 additions
and
283 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,15 @@ | ||
package migrations | ||
|
||
import ( | ||
"context" | ||
"xorm.io/xorm" | ||
) | ||
|
||
func addUserLanguage(x *xorm.Engine) error { | ||
func addUserLanguage(ctx context.Context, x *xorm.Engine) error { | ||
type User struct { | ||
ID string `xorm:"not null pk autoincr BIGINT(20) id"` | ||
Username string `xorm:"not null default '' VARCHAR(50) UNIQUE username"` | ||
Language string `xorm:"not null default '' VARCHAR(100) language"` | ||
} | ||
return x.Sync(new(User)) | ||
return x.Context(ctx).Sync(new(User)) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.