Fixed list detection
authorAlexander Ebert <ebert@woltlab.com>
Mon, 5 Sep 2016 15:54:43 +0000 (17:54 +0200)
committerAlexander Ebert <ebert@woltlab.com>
Mon, 5 Sep 2016 15:54:51 +0000 (17:54 +0200)
wcfsetup/install/files/js/3rdParty/redactor2/plugins/WoltLabCaret.js

index 875a49f9d23b9dfe1be9010230d21e1b3a45b25b..829afbf3bd07ef766714166b0e6703da529b29c9 100644 (file)
@@ -198,7 +198,7 @@ $.Redactor.prototype.WoltLabCaret = function() {
                        if (block.nodeName.match(/^H\d$/)) {
                                return;
                        }
-                       else if (block.closest('ol, ul', this.$editor[0]) !== null) {
+                       else if ($(block).closest('ol, ul', this.$editor[0]).length) {
                                return;
                        }