diff --git a/src/xterm.js b/src/xterm.js index 6be13675..f82d46b5 100644 --- a/src/xterm.js +++ b/src/xterm.js @@ -1437,7 +1437,7 @@ Terminal.prototype.deregisterLinkMatcher = function(matcherId) { * Gets whether the terminal has an active selection. */ Terminal.prototype.hasSelection = function() { - return !!(this.selectionManager && this.selectionManager.hasSelection); + return this.selectionManager ? this.selectionManager.hasSelection : false; }; /**