We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6025a7b commit bccfb74Copy full SHA for bccfb74
components/loops_so/actions/delete-contact/delete-contact.mjs
@@ -29,15 +29,18 @@ export default {
29
},
30
31
async run({ $ }) {
32
- const { // eslint-disable-next-line no-unused-vars
33
- loops, infoAlert, ...data
+ const {
+ loops, email, userId,
34
} = this;
35
- if (!data) {
+ if (!email && !userId) {
36
throw new ConfigurationError("You must provide either the contact's email address or user ID.");
37
}
38
const response = await loops.deleteContact({
39
$,
40
- data,
+ data: {
41
+ email,
42
+ userId,
43
+ },
44
});
45
46
const summary = response?.success
0 commit comments