Browse Source

Fix load issue

Nathaniel van Diepen 9 years ago
parent
commit
e4684870e9
1 changed files with 2 additions and 1 deletions
  1. 2 1
      site/api/index.php

+ 2 - 1
site/api/index.php

@@ -1,4 +1,5 @@
 <?php
+	error_reporting(E_ERROR);
 	header('Content-type: application/json');
 	header('Access-Control-Allow-Origin: *');
 	require_once("../../header.php");
@@ -122,9 +123,9 @@
 							$chan['canaccess'] = true;
 						}
 						$res2 = atheme_command(get_conf('xmlrpc-server'),get_conf('xmlrpc-port'),get_conf('xmlrpc-path'),USER_IP,$_COOKIE['user'],$_SESSION['password'],'ChanServ','flags',array($name));
+						$users = array();
 						if($res2[0]){
 							$res2 = explode('&#10;',$res2[1]);
-							$users = array();
 							foreach($res2 as $kk => $row2){
 								if($kk > 1 && $kk < count($res2)-2){
 									$user = array(