Browse Source

Fix bbcode toolbar error

spaghetti 7 years ago
parent
commit
16c1e41e53
1 changed files with 1 additions and 1 deletions
  1. 1
    1
      static/functions/bbcode.js

+ 1
- 1
static/functions/bbcode.js View File

26
 }
26
 }
27
 
27
 
28
 function BBEditor(box) {
28
 function BBEditor(box) {
29
-  if (box.previousSibling.className == 'bbcode_bar') return
29
+  if (box.previousSibling && box.previousSibling.className == 'bbcode_bar') return
30
   let buttons = [
30
   let buttons = [
31
     {short:'B', name:'Bold', wrap:['[b]','[/b]']},
31
     {short:'B', name:'Bold', wrap:['[b]','[/b]']},
32
     {short:'I', name:'Italic', wrap:['[i]','[/i]']},
32
     {short:'I', name:'Italic', wrap:['[i]','[/i]']},

Loading…
Cancel
Save