Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
nleush committed Sep 12, 2024
2 parents d025a2e + 559df2a commit 5f768db
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 4 deletions.
2 changes: 2 additions & 0 deletions lib/core.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@

import * as htmlUtils from './html-utils.js';
import * as metaUtils from './plugins/system/meta/utils.js';
import mediaPlugin from './plugins/validators/media.js';

const plugins = pluginLoader._plugins,
pluginsModules = pluginLoader._pluginsModules,
Expand All @@ -26,6 +27,7 @@
htmlUtils: htmlUtils,
metaUtils: metaUtils,
plugins: pluginsModules,
prepareLinkMedia: mediaPlugin.prepareLink,
log: log,
cache: cache
};
Expand Down
1 change: 0 additions & 1 deletion lib/plugins/validators/sync/01_ignorelist.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ export default {
prepareLink: function(whitelistRecord, options, link, plugin) {

if (!link.error
&& link.accept // for ones that require validations for now, e.g. MP4 videos
&& link.href
&& CONFIG.IGNORE_DOMAINS_RE && CONFIG.IGNORE_DOMAINS_RE instanceof Array
&& CONFIG.IGNORE_DOMAINS_RE.some(function(re) {
Expand Down
10 changes: 7 additions & 3 deletions static/js/iframely.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,12 @@
}

$.support.cors = true;

if (!$.iframely.defaults.endpoint) {
console.warn('Set "$.iframely.defaults.endpoint" to make requests, e.g. "https://yourdomain.com/iframely".')
return;
}

$.ajax({
crossDomain: true,
url: $.iframely.defaults.endpoint,
Expand All @@ -191,9 +197,7 @@
});
};

$.iframely.defaults = {
endpoint: "//iframely.com/iframely"
};
$.iframely.defaults = {};

$.iframely.get = function(endpoint, query, cb) {
$.ajax({
Expand Down

0 comments on commit 5f768db

Please # to comment.