continue subscriptions and coins
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
const admin = require("firebase-admin");
|
||||
const { FieldValue } = require("firebase-admin/firestore");
|
||||
const {
|
||||
onDocumentDeleted,
|
||||
onDocumentCreated,
|
||||
@@ -126,7 +127,7 @@ async function clearAllUserData(userID) {
|
||||
const snapshot = await ref.where(arrayName, "array-contains", userID).get();
|
||||
snapshot.forEach((item) =>
|
||||
item.ref.update({
|
||||
[arrayName]: admin.firestore.FieldValue.arrayRemove(userID),
|
||||
[arrayName]: FieldValue.arrayRemove(userID),
|
||||
}),
|
||||
);
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user