mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-08-13 01:20:54 +00:00
Add tests, fix some bugs uncovered by the tests
This commit is contained in:
parent
8a24ac37ab
commit
0c9e7bb97d
7 changed files with 261 additions and 30 deletions
|
@ -86,7 +86,12 @@ func RequestRemoteData(remoteCommand, data string, auth AuthInfo) (responseStr s
|
|||
authKey: []string{auth.TwitchUsername},
|
||||
}
|
||||
|
||||
resp, err := backendHttpClient.PostForm(destUrl, formData)
|
||||
sealedForm, err := SealRequest(formData)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
||||
resp, err := backendHttpClient.PostForm(destUrl, sealedForm)
|
||||
if err != nil {
|
||||
return "", err
|
||||
}
|
||||
|
@ -117,7 +122,12 @@ func FetchBacklogData(chatSubs, channelSubs []string) ([]ClientMessage, error) {
|
|||
"channelSubs": channelSubs,
|
||||
}
|
||||
|
||||
resp, err := backendHttpClient.PostForm(getBacklogUrl, formData)
|
||||
sealedForm, err := SealRequest(formData)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
resp, err := backendHttpClient.PostForm(getBacklogUrl, sealedForm)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
@ -152,7 +162,6 @@ func GenerateKeys(outputFile, serverId, theirPublicStr string) {
|
|||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
log.Print(theirPublic)
|
||||
output.TheirPublicKey = theirPublic
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue