@live-change/email-service 0.2.24 → 0.2.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/auth.js +7 -1
- package/package.json +3 -3
package/auth.js
CHANGED
|
@@ -123,10 +123,16 @@ definition.trigger({
|
|
|
123
123
|
validation: ['nonEmpty']
|
|
124
124
|
}
|
|
125
125
|
},
|
|
126
|
-
async execute({ user, email }, {
|
|
126
|
+
async execute({ user, email }, { service }, emit) {
|
|
127
127
|
if(!email) throw new Error("no email")
|
|
128
128
|
const emailData = await Email.get(email)
|
|
129
129
|
if(emailData) throw { properties: { email: 'taken' } }
|
|
130
|
+
await service.trigger({
|
|
131
|
+
type: 'contactConnected',
|
|
132
|
+
contactType: 'email_Email',
|
|
133
|
+
contact: email,
|
|
134
|
+
user
|
|
135
|
+
})
|
|
130
136
|
emit({
|
|
131
137
|
type: 'emailConnected',
|
|
132
138
|
user, email
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@live-change/email-service",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.28",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -21,12 +21,12 @@
|
|
|
21
21
|
"url": "https://www.viamage.com/"
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@live-change/framework": "0.
|
|
24
|
+
"@live-change/framework": "0.6.0",
|
|
25
25
|
"got": "^11.8.3",
|
|
26
26
|
"html-to-text": "8.1.0",
|
|
27
27
|
"inline-css": "3.0.0",
|
|
28
28
|
"jsdom": "^18.1.1",
|
|
29
29
|
"nodemailer": "^6.7.2"
|
|
30
30
|
},
|
|
31
|
-
"gitHead": "
|
|
31
|
+
"gitHead": "34309fef58572e1a8794b52438430dd421c57d65"
|
|
32
32
|
}
|