Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- exports.handleVoteKarma = functions.database
- .ref('upvotes/{postId}')
- .onUpdate(async change => {
- const scoreBefore = change.before.val() || 0;
- const scoreAfter = change.after.val();
- //This {postId} should be the same as the one above for the upvotes/{postId}
- adb.ref('{item}/{loc}/{postId}/score').once('value').then((usr) => {
- });
- return null;
- });
Add Comment
Please, Sign In to add comment