Skip to content

Commit 8e8e536

Browse files
author
Jesse Pollak
committed
update with payment@0.0.6
1 parent 5d6c2b0 commit 8e8e536

File tree

3 files changed

+9
-5
lines changed

3 files changed

+9
-5
lines changed

lib/js/card.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1566,8 +1566,10 @@ hasTextSelected = function(target) {
15661566
if ((target.selectionStart != null) && target.selectionStart !== target.selectionEnd) {
15671567
return true;
15681568
}
1569-
if (typeof document !== "undefined" && document !== null ? (_ref = document.selection) != null ? typeof _ref.createRange === "function" ? _ref.createRange().text : void 0 : void 0 : void 0) {
1570-
return true;
1569+
if ((typeof document !== "undefined" && document !== null ? (_ref = document.selection) != null ? _ref.createRange : void 0 : void 0) != null) {
1570+
if (document.selection.createRange().text) {
1571+
return true;
1572+
}
15711573
}
15721574
return false;
15731575
};

lib/js/jquery.card.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1609,8 +1609,10 @@ hasTextSelected = function(target) {
16091609
if ((target.selectionStart != null) && target.selectionStart !== target.selectionEnd) {
16101610
return true;
16111611
}
1612-
if (typeof document !== "undefined" && document !== null ? (_ref = document.selection) != null ? typeof _ref.createRange === "function" ? _ref.createRange().text : void 0 : void 0 : void 0) {
1613-
return true;
1612+
if ((typeof document !== "undefined" && document !== null ? (_ref = document.selection) != null ? _ref.createRange : void 0 : void 0) != null) {
1613+
if (document.selection.createRange().text) {
1614+
return true;
1615+
}
16141616
}
16151617
return false;
16161618
};

0 commit comments

Comments
 (0)