Skip to content

High-performance browser automation bridge and multi-instance orchestrator with advanced stealth injection and real-time dashboard.

fix formatting and lint from P5 commit

Lb4dbafb29bca
diff --git a/handlers.go b/handlers.go
index a6742bc9..0aff7946 100644
--- a/handlers.go
+++ b/handlers.go
@@ -135,7 +135,7 @@ func (b *Bridge) handleSnapshot(w http.ResponseWriter, r *http.Request) {
w.Header().Set("Content-Type", "text/plain; charset=utf-8")
w.WriteHeader(200)
fmt.Fprintf(w, "# %s\n# %s\n# %d nodes\n\n", title, url, len(flat))
- w.Write([]byte(formatSnapshotText(flat)))
+ _, _ = w.Write([]byte(formatSnapshotText(flat)))
return
}
@@ -317,7 +317,7 @@ func (b *Bridge) actionRegistry() map[string]ActionFunc {
}
// Optional: wait for navigation after click (e.g. link clicks)
if req.WaitNav {
- chromedp.Run(ctx, chromedp.Sleep(waitNavDelay))
+ _ = chromedp.Run(ctx, chromedp.Sleep(waitNavDelay))
}
return map[string]any{"clicked": true}, nil
},
diff --git a/snapshot_test.go b/snapshot_test.go
index 6be9c3bf..2b0e39dd 100644
--- a/snapshot_test.go
+++ b/snapshot_test.go
@@ -181,9 +181,9 @@ func TestDiffSnapshot(t *testing.T) {
{Ref: "e2", Role: "link", Name: "Old Link", NodeID: 30},
}
curr := []A11yNode{
- {Ref: "e0", Role: "button", Name: "Submit", NodeID: 10}, // unchanged
+ {Ref: "e0", Role: "button", Name: "Submit", NodeID: 10}, // unchanged
{Ref: "e1", Role: "textbox", Name: "Email", NodeID: 20, Value: "hi"}, // changed (value)
- {Ref: "e3", Role: "link", Name: "New Link", NodeID: 40}, // added
+ {Ref: "e3", Role: "link", Name: "New Link", NodeID: 40}, // added
}
added, changed, removed := diffSnapshot(prev, curr)