Fix Juno and Phoenix validations

This commit is contained in:
artrejo
2022-01-21 08:20:29 -08:00
parent 1b1371381e
commit 899d7459c1
3 changed files with 6 additions and 4 deletions

View File

@@ -155,7 +155,7 @@ export class PhoenixClient {
public static getPhoenixEndpoint(): string {
const phoenixEndpoint =
userContext.features.phoenixEndpoint ?? userContext.features.junoEndpoint ?? configContext.JUNO_ENDPOINT;
if (validateEndpoint(phoenixEndpoint, configContext.allowedJunoOrigins)) {
if (!validateEndpoint(phoenixEndpoint, configContext.allowedJunoOrigins)) {
const error = `${phoenixEndpoint} not allowed as juno endpoint`;
console.error(error);
throw new Error(error);