The app is now using a fake user-agent in order to prevent being taken for a bot
MODIFY
app/app.go
app/app.go
@@ -98,6 +98,7 @@ func Run() {
window.RegisterCommand(commandimpls.NewManualCommand())
window.RegisterCommand(commandimpls.NewFixLayoutCommand(window))
window.RegisterCommand(commandimpls.NewChatHeaderCommand(window))
+ window.RegisterCommand(commandimpls.NewFriendsCommand(discord))
})
}()
@@ -123,7 +124,7 @@ func attemptLogin(loginMessage string, app *tview.Application, configuration *co
session, discordError = login(loginMessage)
})
} else {
- session, discordError = discordgo.New(configuration.Token)
+ session, discordError = discordgo.New("Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:66.0) Gecko/20100101 Firefox/66.0", configuration.Token)
}
if discordError != nil {

MODIFY
go.mod
go.mod
@@ -20,6 +20,8 @@ require (
github.com/rivo/uniseg v0.0.0-20190313204849-f699dde9c340 // indirect
github.com/robertkrimen/otto v0.0.0-20180617131154-15f95af6e78d
github.com/tadvi/systray v0.0.0-20190226123456-11a2b8fa57af // indirect
+ golang.org/x/crypto v0.0.0-20190418165655-df01cb2cc480 // indirect
+ golang.org/x/sys v0.0.0-20190419153524-e8e3143a4f4a // indirect
gopkg.in/sourcemap.v1 v1.0.5 // indirect
gopkg.in/toast.v1 v1.0.0-20180812000517-0a84660828b2 // indirect
)

MODIFY
go.sum
go.sum
@@ -74,9 +74,12 @@ github.com/tadvi/systray v0.0.0-20190226123456-11a2b8fa57af h1:6yITBqGTE2lEeTPG0
github.com/tadvi/systray v0.0.0-20190226123456-11a2b8fa57af/go.mod h1:4F09kP5F+am0jAwlQLddpoMDM+iewkxxt6nxUQ5nq5o=
golang.org/x/crypto v0.0.0-20190403202508-8e1b8d32e692 h1:GRhHqDOgeDr6QDTtq9gn2O4iKvm5dsbfqD/TXb0KLX0=
golang.org/x/crypto v0.0.0-20190403202508-8e1b8d32e692/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE=
+golang.org/x/crypto v0.0.0-20190418165655-df01cb2cc480 h1:O5YqonU5IWby+w98jVUG9h7zlCWCcH4RHyPVReBmhzk=
+golang.org/x/crypto v0.0.0-20190418165655-df01cb2cc480/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE=
golang.org/x/sys v0.0.0-20181128092732-4ed8d59d0b35/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e h1:nFYrTHrdrAOpShe27kaFHjsqYSEQ0KWqdWLu3xuZJts=
golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
+golang.org/x/sys v0.0.0-20190419153524-e8e3143a4f4a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=
gopkg.in/DATA-DOG/go-sqlmock.v1 v1.3.0 h1:FVCohIoYO7IJoDDVpV2pdq7SgrMH6wHnuTyrdrxJNoY=

The app is now using a fake user-agent in order to prevent being taken for a bot