Skip to content

Commit

Permalink
Merge pull request #960 from stakwork/debug/meme_server
Browse files Browse the repository at this point in the history
added logs for meme server to debug
  • Loading branch information
elraphty authored Nov 17, 2023
2 parents e39b3b9 + 22d6a65 commit 3142836
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions handlers/meme.go
Original file line number Diff line number Diff line change
Expand Up @@ -141,12 +141,16 @@ func SignChallenge(challenge string) db.RelaySignerResponse {
func GetMemeToken(id string, sig string) (string, db.MemeTokenSuccess) {
memeUrl := fmt.Sprintf("%s/verify", config.MemeUrl)

fmt.Println("MEME URL ===", memeUrl)

formData := url.Values{
"id": {id},
"sig": {sig},
"pubkey": {config.RelayNodeKey},
}

fmt.Println("TOKEN DATA ===", formData)

res, err := http.PostForm(memeUrl, formData)

if err != nil {
Expand All @@ -169,6 +173,7 @@ func GetMemeToken(id string, sig string) (string, db.MemeTokenSuccess) {

return "", tokenSuccess
} else {
fmt.Println("MEME TOKEN ERROR === ", err)
var tokenError string

// Unmarshal result
Expand Down

0 comments on commit 3142836

Please sign in to comment.