Operator Panel: Validate array to mitigate warnings when no extension(s) assigned to current user.
This commit is contained in:
parent
80f2b3cb0f
commit
93bcc5247f
|
|
@ -420,7 +420,7 @@ if (is_array($activity)) foreach ($activity as $extension => $ext) {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if (sizeof($user_extensions) > 0) {
|
if (is_array($user_extensions) && @sizeof($user_extensions) > 0) {
|
||||||
echo "<table width='100%'><tr><td>";
|
echo "<table width='100%'><tr><td>";
|
||||||
if (is_array($user_extensions)) foreach ($user_extensions as $ext_block) {
|
if (is_array($user_extensions)) foreach ($user_extensions as $ext_block) {
|
||||||
echo $ext_block;
|
echo $ext_block;
|
||||||
|
|
@ -429,11 +429,11 @@ if (sizeof($user_extensions) > 0) {
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($_REQUEST['group'] != '') {
|
if ($_REQUEST['group'] != '') {
|
||||||
if (sizeof($user_extensions) > 0) { echo "<br>"; }
|
if (is_array($user_extensions) && @sizeof($user_extensions) > 0) { echo "<br>"; }
|
||||||
echo "<strong style='color: black;'>".ucwords(escape($_REQUEST['group']))."</strong>";
|
echo "<strong style='color: black;'>".ucwords(escape($_REQUEST['group']))."</strong>";
|
||||||
echo "<br><br>";
|
echo "<br><br>";
|
||||||
}
|
}
|
||||||
else if (sizeof($user_extensions) > 0) {
|
else if (is_array($user_extensions) && @sizeof($user_extensions) > 0) {
|
||||||
echo "<br>";
|
echo "<br>";
|
||||||
echo "<strong style='color: black;'>".$text['label-other_extensions']."</strong>";
|
echo "<strong style='color: black;'>".$text['label-other_extensions']."</strong>";
|
||||||
echo "<br><br>";
|
echo "<br><br>";
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue