Adds element existence check to avoid JS errors in welcome page.

This commit is contained in:
hristoterezov 2014-09-25 15:01:18 +03:00
parent 215656cb8b
commit 5e58327a3f
1 changed files with 6 additions and 3 deletions

5
app.js
View File

@ -1138,12 +1138,15 @@ $(document).ready(function () {
if (interfaceConfig.SHOW_JITSI_WATERMARK) {
var leftWatermarkDiv
= $("#welcome_page_header div[class='watermark leftwatermark']");
if(leftWatermarkDiv && leftWatermarkDiv.length > 0)
{
leftWatermarkDiv.css({display: 'block'});
leftWatermarkDiv.parent().get(0).href
= interfaceConfig.JITSI_WATERMARK_LINK;
}
}
if (interfaceConfig.SHOW_BRAND_WATERMARK) {
var rightWatermarkDiv
= $("#welcome_page_header div[class='watermark rightwatermark']");