Commit 70f15709 authored by JC Brand's avatar JC Brand

Bugfix. If controlbox is not there, undefined is returned.:wq

parent 70135ba0
......@@ -214,9 +214,9 @@
},
insertIntoDOM: function () {
var $cbox = converse.chatboxviews.get("controlbox").$el;
if ($cbox.length) {
this.$el.insertAfter($cbox);
var view = converse.chatboxviews.get("controlbox");
if (view) {
this.$el.insertAfter(view.$el);
} else {
$('#conversejs').prepend(this.$el);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment