Skip to content

Commit f2647ed

Browse files
committed
feat: send primary role in payload during user creation
Signed-off-by: Rakib Ansary <[email protected]>
1 parent 77b5293 commit f2647ed

File tree

1 file changed

+6
-4
lines changed
  • web-assets/auth0/prod-tenant/database

1 file changed

+6
-4
lines changed

web-assets/auth0/prod-tenant/database/create.js

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@
5050
"isoAlpha3Code": countryObj.alpha3,
5151
"isoAlpha2Code": countryObj.alpha2
5252
},
53+
"primaryRole": user.user_metadata.primaryRole,
5354
"regSource": regSource,
5455
"utmSource": utmSource,
5556
"utmMedium": utmMedium,
@@ -59,16 +60,17 @@
5960
"afterActivationURL": encodeURIComponent(afterActivationURL)
6061
}
6162
};
63+
// console.log("SignUp....", user, data);
6264
request.post({
6365
url: "https://api."+configuration.DOMAIN+"/v3/users",
6466
json: data
6567
//for more options check:
6668
//https://github.com/mikeal/request#requestoptions-callback
6769
}, function (err, response, body) {
6870

69-
console.log(err);
70-
console.log(response.statusCode);
71-
console.log(body);
71+
// console.log(err);
72+
// console.log(response.statusCode);
73+
// console.log(body);
7274

7375
if (err) return callback(err);
7476

@@ -99,4 +101,4 @@
99101
callback(null);
100102
}); //end post request
101103
//callback(null);
102-
}
104+
}

0 commit comments

Comments
 (0)