Made extra modify-able

This commit is contained in:
Tracker-Friendly 2024-07-21 10:04:07 +01:00
parent f3de9b4eb4
commit 8b943d4a08
1 changed files with 3 additions and 2 deletions

View File

@ -8,8 +8,9 @@ import (
func main() {
fmt.Println("HashCash online! (no, curious console-dweller, this isn't a cryptocurrency miner)")
fmt.Println("Beginning proof of work (this may take a while)...")
pow := hashcash.New(20, 16, "I love burgernotes!")
extra := js.Global().Get("resourceExtra").String()
fmt.Println("Beginning proof of work on " + extra + "(this may take a while)...")
pow := hashcash.New(20, 16, extra)
stamp, err := pow.Mint("signup")
if err != nil {
js.Global().Set("returnVar", js.ValueOf(err.Error()))