Skip to content

Commit 51db909

Browse files
committed
refactor: apply staticcheck
1 parent 37d2491 commit 51db909

File tree

6 files changed

+3
-11
lines changed

6 files changed

+3
-11
lines changed

cmd/vinegar/bootstrapper_setup_rblx.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ func (b *bootstrapper) setupDeployment() error {
5959
if b.bin.Channel != "" && b.bin.Channel != "LIVE" {
6060
b.message("Writing Registry")
6161
if err := b.pfx.RegistryAdd(channelKey, "www.roblox.com", b.bin.Channel); err != nil {
62-
return fmt.Errorf("set channel reg: %w")
62+
return fmt.Errorf("set channel reg: %w", err)
6363
}
6464
}
6565

cmd/vinegar/manager.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ func (a *app) newManager() *manager {
6767
},
6868
"run": m.run,
6969

70-
"prefix-kill": m.pfx.Kill,
70+
"prefix-kill": m.killPrefix,
7171
"delete-prefix": m.deletePrefixes,
7272
"delete-studio": m.deleteDeployments,
7373
"clear-cache": m.clearCache,

cmd/vinegar/manager_actions.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,6 @@ func (m *manager) saveConfig() {
7474
banner.SetTitle(fmt.Sprintf("Invalid: %v", err))
7575
banner.SetRevealed(true)
7676
slog.Info("Configuration validation error", "err", err)
77-
return
7877
}
7978

8079
func (m *manager) showAbout() {

internal/adwaux/adwaux.go

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,11 @@ package adwaux
44

55
import (
66
"reflect"
7-
"regexp"
87
"strings"
98

109
"github.com/jwijenbergh/puregotk/v4/adw"
1110
)
1211

13-
// Transform value names to their Title Case counterparts
14-
var configNameExp = regexp.MustCompile(`([a-z])([A-Z])`)
15-
1612
type StructPage struct {
1713
sv reflect.Value
1814
groups map[string]*adw.PreferencesGroup

internal/netutil/netutil.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -54,8 +54,7 @@ func DownloadProgress(url, file string, pbar *gtk.ProgressBar) error {
5454
pbar: pbar,
5555
}
5656

57-
var idlecb glib.SourceFunc
58-
idlecb = func(uintptr) bool {
57+
var idlecb glib.SourceFunc = func(uintptr) bool {
5958
pbar.SetFraction(float64(pc.current) / float64(pc.total))
6059
return pc.current != pc.total
6160
}

internal/studiorpc/studiorpc.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ import (
1111
"github.com/sewnie/rbxweb"
1212
)
1313

14-
const appID = "1159891020956323923"
15-
1614
type StudioRPC struct {
1715
presence drpc.Activity
1816
client *drpc.Client

0 commit comments

Comments
 (0)