Skip to content

Commit

Permalink
Updated dependencies
Browse files Browse the repository at this point in the history
  • Loading branch information
ItalyPaleAle committed Aug 20, 2020
1 parent a91b0fa commit a20f835
Show file tree
Hide file tree
Showing 5 changed files with 1,568 additions and 1,252 deletions.
7 changes: 5 additions & 2 deletions app/tailwind.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ module.exports = {

},
plugins: [

]

],
future: {
removeDeprecatedGapUtilities: true,
},
}
32 changes: 17 additions & 15 deletions auth0/02-notify.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,21 +20,23 @@ function (user, context, callback) {
value2: user.email,
value3: role
};
const request = require('request');
request({
uri: configuration.WEBHOOK_URL,
const fetch = require('node-fetch@2.6.0');
fetch(configuration.WEBHOOK_URL, {
method: 'POST',
json: true,
body
}, (error, response) => {
if (error) {
// Fail on errors, even for notifications
console.log(error);
body: JSON.stringify(body),
headers: {'Content-Type': 'application/json'}
})
// Ensure the response has a valid status code
.then((response) => {
if (response.ok) {
return callback(null, user, context);
} else {
return Promise.reject('Invalid response status code');
}
})
// Catch errors and fail (fail the login even if the notification fails to send)
.catch((err) => {
console.error(err);
callback(new Error('Error sending the notification'));
}
else {
// Continue
callback(null, user, context);
}
});
});
}
2 changes: 1 addition & 1 deletion auth0/03-wait-logic.js
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ function (user, context, callback) {
const owners = /*%OWNERS%*/;

// Get the Auth0 management client
const ManagementClient = require('auth0@2.19.0').ManagementClient;
const ManagementClient = require('auth0@2.27.0').ManagementClient;
const management = new ManagementClient({
domain: auth0.domain,
clientId: configuration.AUTH0_CLIENT_ID,
Expand Down
Loading

0 comments on commit a20f835

Please sign in to comment.