fix: Enable use of self-hosted Iframely without API key

closes #6694
This commit is contained in:
Tom Moor
2024-03-21 19:58:12 -04:00
parent bd2b32f9d5
commit 1924c232fb
2 changed files with 10 additions and 5 deletions

View File

@@ -7,7 +7,8 @@ import {
import env from "./env";
import Iframely from "./iframely";
const enabled = !!env.IFRAMELY_API_KEY && !!env.IFRAMELY_URL;
const isDefaultHost = env.IFRAMELY_URL === Iframely.defaultUrl;
const enabled = (isDefaultHost && !!env.IFRAMELY_API_KEY) || !!env.IFRAMELY_URL;
if (enabled) {
PluginManager.add([