Skip to content

Commit

Permalink
Merge pull request #1141 from creative-commoners/pulls/1.6/entwine-on…
Browse files Browse the repository at this point in the history
…e-patch

FIX Patch Entwine to ignore missing methods in one()
  • Loading branch information
emteknetnz authored Oct 19, 2020
2 parents 3643b40 + 7727d10 commit 86328aa
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 6 deletions.
2 changes: 1 addition & 1 deletion client/dist/js/vendor.js

Large diffs are not rendered by default.

10 changes: 8 additions & 2 deletions thirdparty/jquery-entwine/dist/jquery.entwine-dist.js
Original file line number Diff line number Diff line change
Expand Up @@ -1008,8 +1008,14 @@ catch (e) {
if (funcs[i].selector.matches(el)) {
var ret, tmp_i = el.i, tmp_f = el.f;
el.i = i; el.f = one;
try { ret = funcs[i][funcprop].apply(namespace.$(el), args); }
finally { el.i = tmp_i; el.f = tmp_f; }
try {
if (typeof funcs[i][funcprop] == 'function') {
ret = funcs[i][funcprop].apply(namespace.$(el), args);
}
} finally {
el.i = tmp_i;
el.f = tmp_f;
}
return ret;
}
}
Expand Down
12 changes: 9 additions & 3 deletions thirdparty/jquery-entwine/src/jquery.entwine.js
Original file line number Diff line number Diff line change
Expand Up @@ -203,9 +203,15 @@ catch (e) {
if (funcs[i].selector.matches(el)) {
var ret, tmp_i = el.i, tmp_f = el.f;
el.i = i; el.f = one;
try { ret = funcs[i][funcprop].apply(namespace.$(el), args); }
finally { el.i = tmp_i; el.f = tmp_f; }
return ret;
try {
if (typeof funcs[i][funcprop] == 'function') {
ret = funcs[i][funcprop].apply(namespace.$(el), args);
}
} finally {
el.i = tmp_i;
el.f = tmp_f;
}
return ret;
}
}
// If we didn't find a entwine-defined function, but there is a non-entwine function to use as a base, try that
Expand Down

0 comments on commit 86328aa

Please sign in to comment.