Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4098ed7

Browse files
CR's fixes
1 parent 8266338 commit 4098ed7

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

coderd/coderd.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,6 @@ import (
1919
"sync/atomic"
2020
"time"
2121

22-
"github.com/coder/coder/v2/coderd/prebuilds"
23-
2422
"github.com/andybalholm/brotli"
2523
"github.com/go-chi/chi/v5"
2624
"github.com/go-chi/chi/v5/middleware"
@@ -47,6 +45,7 @@ import (
4745
"github.com/coder/coder/v2/coderd/entitlements"
4846
"github.com/coder/coder/v2/coderd/files"
4947
"github.com/coder/coder/v2/coderd/idpsync"
48+
"github.com/coder/coder/v2/coderd/prebuilds"
5049
"github.com/coder/coder/v2/coderd/runtimeconfig"
5150
"github.com/coder/coder/v2/coderd/webpush"
5251

coderd/workspaces.go

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ import (
1111
"strconv"
1212
"time"
1313

14-
"github.com/coder/coder/v2/coderd/prebuilds"
15-
1614
"github.com/dustin/go-humanize"
1715
"github.com/go-chi/chi/v5"
1816
"github.com/google/uuid"
@@ -31,6 +29,7 @@ import (
3129
"github.com/coder/coder/v2/coderd/httpapi"
3230
"github.com/coder/coder/v2/coderd/httpmw"
3331
"github.com/coder/coder/v2/coderd/notifications"
32+
"github.com/coder/coder/v2/coderd/prebuilds"
3433
"github.com/coder/coder/v2/coderd/rbac"
3534
"github.com/coder/coder/v2/coderd/rbac/policy"
3635
"github.com/coder/coder/v2/coderd/schedule"
@@ -897,7 +896,7 @@ func claimPrebuild(ctx context.Context, claimer prebuilds.Claimer, db database.S
897896
logger.Error(ctx, "unable to find claimed workspace by ID", slog.Error(err), slog.F("claimed_prebuild_id", (*claimedID).String()))
898897
return nil, xerrors.Errorf("find claimed workspace by ID %q: %w", (*claimedID).String(), err)
899898
}
900-
return &lookup, err
899+
return &lookup, nil
901900
}
902901

903902
func (api *API) notifyWorkspaceCreated(

0 commit comments

Comments
 (0)