Compare commits
2 Commits
v2025.12.1
...
v2025.12.1
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6303d535bc | ||
|
|
b464d8f563 |
2
app.go
2
app.go
@@ -239,7 +239,6 @@ func (a *App) CheckUpdate(flag int) {
|
||||
releaseVersion := &models.GitHubReleaseVersion{}
|
||||
_, err := resty.New().R().
|
||||
SetResult(releaseVersion).
|
||||
SetHeader("Authorization", "Bearer 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").
|
||||
Get("https://api.github.com/repos/ArvinLovegood/go-stock/releases/latest")
|
||||
if err != nil {
|
||||
logger.SugaredLogger.Errorf("get github release version error:%s", err.Error())
|
||||
@@ -250,7 +249,6 @@ func (a *App) CheckUpdate(flag int) {
|
||||
|
||||
tag := &models.Tag{}
|
||||
_, err = resty.New().R().
|
||||
SetHeader("Authorization", "Bearer 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").
|
||||
SetResult(tag).
|
||||
Get("https://api.github.com/repos/ArvinLovegood/go-stock/git/ref/tags/" + releaseVersion.TagName)
|
||||
if err == nil {
|
||||
|
||||
@@ -54,7 +54,6 @@ func TestUpdateCheck(t *testing.T) {
|
||||
SetResult(releaseVersion).
|
||||
SetHeader("Accept", "application/vnd.github+json").
|
||||
SetHeader("X-GitHub-Api-Version", "2022-11-28").
|
||||
SetHeader("Authorization", "Bearer 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").
|
||||
Get("https://api.github.com/repos/ArvinLovegood/go-stock/releases/latest")
|
||||
// https://api.github.com/repos/OWNER/REPO/releases/latest
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user