Fixed selecting text when mouseup occurs outside body element
authorAlexander Ebert <ebert@woltlab.com>
Fri, 6 Feb 2015 14:42:09 +0000 (15:42 +0100)
committerAlexander Ebert <ebert@woltlab.com>
Fri, 6 Feb 2015 14:42:09 +0000 (15:42 +0100)
wcfsetup/install/files/js/WCF.Message.js

index 3a6f796c96d020f0c081c93d2eec4cca77d5f03f..7f6dc427200506f40934f176ba221c7527a0f691 100644 (file)
@@ -2077,7 +2077,7 @@ WCF.Message.Quote.Handler = Class.extend({
                // check if mouseup occured within a <blockquote>
                var $element = event.target;
                while ($element !== $container[0]) {
-                       if ($element.tagName === 'BLOCKQUOTE') {
+                       if ($element === null || $element.tagName === 'BLOCKQUOTE') {
                                this._copyQuote.hide();
                                
                                return;