mirror of
https://github.com/jambonz/jambonz-api-server.git
synced 2026-07-04 19:21:53 +00:00
bugfix: generating new account failed due to null webhook_secret
This commit is contained in:
@@ -291,7 +291,7 @@ router.post('/', async(req, res) => {
|
||||
await validateAdd(req);
|
||||
|
||||
// create webhooks if provided
|
||||
const obj = Object.assign({webhook_secret: secret}, req.body);
|
||||
const obj = {...req.body, webhook_secret: secret};
|
||||
for (const prop of ['registration_hook']) {
|
||||
if (obj[prop]) {
|
||||
obj[`${prop}_sid`] = await Webhook.make(obj[prop]);
|
||||
|
||||
Reference in New Issue
Block a user