chore(webui): go fix modernises boolPtr to new(value)
task check's go fix pass rewrote the test helper to Go 1.26's generic new(v) and marked it //go:fix inline. Committed from the gate rather than left dirty in the tree.
This commit is contained in:
1 parent
45fbed4228
commit
b0c9afa0f0
1 file changed
+3
-2
@@ -40,7 +40,7 @@ func TestAuthorizeTaskMutationOrigin(t *testing.T) {
|
||||
},
|
||||
{
|
||||
name: "1b. proxied https: trust enabled via Cfg holder, X-Forwarded-Proto https, plain HTTP, Origin https",
|
||||
trustForwardedCfg: boolPtr(true),
|
||||
trustForwardedCfg: new(true),
|
||||
forwardedProto: "https",
|
||||
requestHost: "archie.catlow.cloud",
|
||||
tls: false,
|
||||
@@ -237,8 +237,9 @@ func TestAuthorizeTaskMutationOrigin(t *testing.T) {
|
||||
}
|
||||
}
|
||||
|
||||
//go:fix inline
|
||||
func boolPtr(b bool) *bool {
|
||||
return &b
|
||||
return new(b)
|
||||
}
|
||||
|
||||
func TestWorkRequestOriginProxy(t *testing.T) {
|
||||
|
||||
Reference in new issue
Block a user