pull/55/head
Dominik Michno 2019-05-03 10:50:33 -04:00 committed by GitHub
parent f0d52c4431
commit 534e6e1f0b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -48,7 +48,9 @@ function PassportHelper () {
const protocol = strategies[key].protocol
const callbackURL = strategies[key].callback
let baseURL = ''
if (sails.config.custom.baseURL && sails.config.custom.baseURL !== null) {
if (process.env.BASE_URL) {
baseURL = process.env.BASE_URL
} else if (sails.config.custom.baseURL && sails.config.custom.baseURL !== null) {
baseURL = sails.config.custom.baseURL
} else {
sails.log.warn('Please add \'appUrl\' to configuration')