style: gofmt struct-tag alignment across v0 files
v0 landed with a few misaligned struct tags and fields; gofmt -l flagged categories.go, topics.go, discourse_test.go and the smoke fake. Alignment only, no behavior change, so the tree passes the gofmt gate cleanly.
This commit is contained in:
+4
-4
@@ -82,15 +82,15 @@ func newFake(t *testing.T) *fakeDiscourse {
|
||||
}
|
||||
if req.Name == "denied" { // simulate a non-admin key
|
||||
writeJSON(w, 403, map[string]any{
|
||||
"errors": []string{"You are not permitted to view the requested resource."},
|
||||
"error_description": "Access denied",
|
||||
"errors": []string{"You are not permitted to view the requested resource."},
|
||||
"error_description": "Access denied",
|
||||
})
|
||||
return
|
||||
}
|
||||
f.mu.Lock()
|
||||
cat := Category{
|
||||
ID: f.nextCat, Name: req.Name,
|
||||
Slug: strings.ToLower(strings.ReplaceAll(req.Name, " ", "-")),
|
||||
Slug: strings.ToLower(strings.ReplaceAll(req.Name, " ", "-")),
|
||||
Color: req.Color, TextColor: req.TextColor, Position: req.Position,
|
||||
}
|
||||
f.nextCat++
|
||||
@@ -158,7 +158,7 @@ func newFake(t *testing.T) *fakeDiscourse {
|
||||
case http.MethodPut:
|
||||
var body struct {
|
||||
Post struct {
|
||||
Raw string `json:"raw"`
|
||||
Raw string `json:"raw"`
|
||||
EditReason string `json:"edit_reason"`
|
||||
} `json:"post"`
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user