mirror of
https://gitlab.com/timvisee/send.git
synced 2025-12-06 14:10:53 +03:00
Enable base URL detection by default with npm start, remove FXA_CLIENT_ID
This commit is contained in:
@@ -212,17 +212,16 @@ conf.validate({ allowed: 'strict' });
|
||||
|
||||
const props = conf.getProperties();
|
||||
|
||||
const deriveBaseUrl = (req) => {
|
||||
if (props.detect_base_url) {
|
||||
const protocol = req.secure ? 'https://' : 'http://';
|
||||
|
||||
return `${protocol}${req.headers.host}`;
|
||||
} else {
|
||||
const deriveBaseUrl = req => {
|
||||
if (!props.detect_base_url) {
|
||||
return props.base_url;
|
||||
}
|
||||
|
||||
const protocol = req.secure ? 'https://' : 'http://';
|
||||
return `${protocol}${req.headers.host}`;
|
||||
};
|
||||
|
||||
module.exports = {
|
||||
...props,
|
||||
deriveBaseUrl,
|
||||
deriveBaseUrl
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user