diff --git a/set-env.ts b/set-env.ts index 2e232904..95a5431a 100644 --- a/set-env.ts +++ b/set-env.ts @@ -19,13 +19,17 @@ const prodEnvConfig = { const envConfig: { [key: string]: any } = process.env.ANGULAR_ENV === 'production' ? prodEnvConfig : devEnvConfig; +const tokenUrl = process.env.STREAM_TOKEN_URL + ? `'${process.env.STREAM_TOKEN_URL}'` + : `''`; + // `environment.ts` file structure const envConfigFile = `export const environment = { ${Object.keys(envConfig).map((k) => `${k}: ${envConfig[k]},`)} apiKey: '${process.env.STREAM_API_KEY}', userId: '${process.env.STREAM_USER_ID}', userToken: '${process.env.STREAM_USER_TOKEN}', - tokenUrl: '${process.env.STREAM_TOKEN_URL}', + tokenUrl: ${tokenUrl}, channelsFilter: ${process.env.STREAM_CHANNELS_FILTER} }; // I am a generated file, do not modify me directly, see set-env script