Last active
October 12, 2022 06:56
-
-
Save nidhi-canopas/2cafb3f68e7eb17d7d1a6b4951491231 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// create ref at path user_scores/:userId | |
ref := client.NewRef("user_scores/" + fmt.Sprint(1)) | |
if err := ref.Set(context.TODO(), map[string]interface{}{"score": 40}); err != nil { | |
log.Fatal(err) | |
} | |
fmt.Println("score added/updated successfully!") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment