Skip to content

Commit 6304478

Browse files
authored
Update to version 1.3.17-STABLE
1 parent e1e8e8f commit 6304478

1 file changed

Lines changed: 14 additions & 11 deletions

File tree

iframeServerBanner.php

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
<?php
22
/*
33
First-Coder Teamspeak 3 Webinterface for everyone
4-
Copyright (C) 2017 by L.Gmann
4+
Copyright (C) 2017 by Multivitamin <multivitamin.wtf> & L.Gmann
55
66
This program is free software: you can redistribute it and/or modify
77
it under the terms of the GNU General Public License as published by
@@ -150,19 +150,22 @@
150150
paintText($image, $textInfos['fontsize'], $textInfos['x'], $textInfos['y'], $textInfos['color'], $textInfos['fontfile'], $text);
151151
};
152152

153-
foreach ($packetmanager['custom'] AS $text=>$textInfos)
153+
if(!empty($packetmanager['custom']))
154154
{
155-
if (!file_exists($textInfos['fontfile']))
156-
{
157-
throw new Exception ('Font File not found! Searched at '.$textInfos['fontfile'].PHP_EOL.'You may need to set the absolute path (from root directory /var/www/...)');
158-
};
159-
160-
if (strpos($text, '%nickname%') !== FALSE)
155+
foreach ($packetmanager['custom'] AS $text=>$textInfos)
161156
{
162-
continue;
157+
if (!file_exists($textInfos['fontfile']))
158+
{
159+
throw new Exception ('Font File not found! Searched at '.$textInfos['fontfile'].PHP_EOL.'You may need to set the absolute path (from root directory /var/www/...)');
160+
};
161+
162+
if (strpos($text, '%nickname%') !== FALSE)
163+
{
164+
continue;
165+
};
166+
167+
paintText($image, $textInfos['fontsize'], $textInfos['x'], $textInfos['y'], $textInfos['color'], $textInfos['fontfile'], $textInfos['text']);
163168
};
164-
165-
paintText($image, $textInfos['fontsize'], $textInfos['x'], $textInfos['y'], $textInfos['color'], $textInfos['fontfile'], $textInfos['text']);
166169
};
167170

168171
/*

0 commit comments

Comments
 (0)