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