fixed some warning messages

This commit is contained in:
Roland Gruber 2006-09-09 11:43:19 +00:00
parent 3752257f4a
commit d4cdd87d0a
1 changed files with 15 additions and 13 deletions

View File

@ -86,6 +86,7 @@ function getSelfServiceOptions($scope, $fields, $attributes) {
$return = array(); $return = array();
$modules = getAvailableModules($scope); $modules = getAvailableModules($scope);
for ($i = 0; $i < sizeof($modules); $i++) { for ($i = 0; $i < sizeof($modules); $i++) {
if (!isset($fields[$modules[$i]])) continue;
$m = new $modules[$i]($scope); $m = new $modules[$i]($scope);
$code = $m->getSelfServiceOptions($fields[$modules[$i]], $attributes); $code = $m->getSelfServiceOptions($fields[$modules[$i]], $attributes);
if (sizeof($code) > 0) $return[$modules[$i]] = $code; if (sizeof($code) > 0) $return[$modules[$i]] = $code;
@ -106,6 +107,7 @@ function checkSelfServiceOptions($scope, $fields, $attributes) {
$return = array('messages' => array(), 'add' => array(), 'del' => array(), 'mod' => array()); $return = array('messages' => array(), 'add' => array(), 'del' => array(), 'mod' => array());
$modules = getAvailableModules($scope); $modules = getAvailableModules($scope);
for ($i = 0; $i < sizeof($modules); $i++) { for ($i = 0; $i < sizeof($modules); $i++) {
if (!isset($fields[$modules[$i]])) continue;
$m = new $modules[$i]($scope); $m = new $modules[$i]($scope);
$result = $m->checkSelfServiceOptions($fields[$modules[$i]], $attributes); $result = $m->checkSelfServiceOptions($fields[$modules[$i]], $attributes);
if (sizeof($result['messages']) > 0) $return['messages'] = array_merge($result['messages'], $return['messages']); if (sizeof($result['messages']) > 0) $return['messages'] = array_merge($result['messages'], $return['messages']);