Skip to content

Instantly share code, notes, and snippets.

@Humberd
Created January 22, 2018 16:51
Show Gist options
  • Save Humberd/6d98e15b9f50e2bf07383df71707af2a to your computer and use it in GitHub Desktop.
Save Humberd/6d98e15b9f50e2bf07383df71707af2a to your computer and use it in GitHub Desktop.
removeuser
export const removeUserFromRankingOnZgloszenieDelete = functions.database.ref('/users/{userId}/zgloszenia/{zgloszenieId}')
.onDelete(event2 => {
const {userId, zgloszenieId} = event2.params;
const {kodKierunku} = event2.data;
return evet2.data.adminRef.root.child(`/ranking/${kodKierunku}/zgloszenia/${zgloszenieId}`).remove()
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment