mirror of
https://github.com/timvisee/send.git
synced 2025-10-05 02:19:26 +02:00
add fxa_required option
This commit is contained in:
parent
9891d1f0ba
commit
17057e725d
7 changed files with 20 additions and 3 deletions
|
@ -15,7 +15,11 @@ module.exports = async function(req) {
|
|||
try {
|
||||
authConfig = await getFxaConfig();
|
||||
authConfig.client_id = config.fxa_client_id;
|
||||
authConfig.fxa_required = config.fxa_required;
|
||||
} catch (e) {
|
||||
if (config.auth_required) {
|
||||
throw new Error('fxa_required is set but no config was found');
|
||||
}
|
||||
// continue without accounts
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue