[Easymod-cvs] easymod/install/em_files/admin em_manage.php,1.3,1.4
Status: Beta
Brought to you by:
wgeric
From: Eric F. <wg...@us...> - 2005-12-22 00:33:46
|
Update of /cvsroot/easymod/easymod/install/em_files/admin In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28502/em_files/admin Modified Files: em_manage.php Log Message: - Changed error message to em_trigger_error Other minor changes Index: em_manage.php =================================================================== RCS file: /cvsroot/easymod/easymod/install/em_files/admin/em_manage.php,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** em_manage.php 9 Dec 2005 23:22:37 -0000 1.3 --- em_manage.php 22 Dec 2005 00:33:31 -0000 1.4 *************** *** 103,107 **** if( !$mod_parser->verify() ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_open', $mod_file); } $mod_parser->parse_header(); --- 103,107 ---- if( !$mod_parser->verify() ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_open', $mod_file); } $mod_parser->parse_header(); *************** *** 159,163 **** if ( !$modder->open($edit_file) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_open', $target_file); } display_mod_action('processed', $action, $target_file); --- 159,163 ---- if ( !$modder->open($edit_file) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_open', $target_file); } display_mod_action('processed', $action, $target_file); *************** *** 169,173 **** if ( !$modder->find($actions_data['find']) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'find', $actions_data['find']); --- 169,173 ---- if ( !$modder->find($actions_data['find']) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'find', $actions_data['find']); *************** *** 182,186 **** if ( !call_user_func(array(&$modder, $action_func), $action_data['code']) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_' . $action_func, $action_data['code']); } $block = 'processed'; --- 182,186 ---- if ( !call_user_func(array(&$modder, $action_func), $action_data['code']) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_' . $action_func, $action_data['code']); } $block = 'processed'; *************** *** 201,205 **** if ( !$modder->in_line_find($inlines_data['in-line-find']) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_inline_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'in-line-find', $inlines_data['in-line-find']); --- 201,205 ---- if ( !$modder->in_line_find($inlines_data['in-line-find']) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_inline_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'in-line-find', $inlines_data['in-line-find']); *************** *** 214,218 **** if ( !call_user_func(array(&$modder, $action_func), $inline_data['code']) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_' . $action_func, $action_data['code']); } $block = 'processed'; --- 214,218 ---- if ( !call_user_func(array(&$modder, $action_func), $inline_data['code']) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_' . $action_func, $action_data['code']); } $block = 'processed'; *************** *** 295,299 **** for( $i = 0, $total = sizeof($sql_parser->warnings); $i < $total; $i++ ) { ! em_handle_error(EM_ERR_WARNING, 'SQL Warning', $sql_parser->warnings[$i]); } } --- 295,299 ---- for( $i = 0, $total = sizeof($sql_parser->warnings); $i < $total; $i++ ) { ! em_trigger_error(EM_ERR_WARNING, 'SQL Warning', $sql_parser->warnings[$i]); } } *************** *** 429,433 **** if ( !$mod_io->make_dir($backup_dir . '/' . dirname($target_file)) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_mkdir_backup', $backup_dir . '/' . dirname($target_file)); } --- 429,433 ---- if ( !$mod_io->make_dir($backup_dir . '/' . dirname($target_file)) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_mkdir_backup', $backup_dir . '/' . dirname($target_file)); } *************** *** 435,439 **** if ( !$mod_io->copy_file($target_file, $backup_dir . '/' . $target_file . '.txt') ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_move_backup', $target_file); } --- 435,439 ---- if ( !$mod_io->copy_file($target_file, $backup_dir . '/' . $target_file . '.txt') ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_move_backup', $target_file); } *************** *** 468,477 **** if ( !$mod_io->make_dir(dirname($copy_files[$i]['to'])) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_mkdir_file', dirname($copy_files[$i]['to'])); } if ( !$mod_io->copy_file($copy_files[$i]['from'], $copy_files[$i]['to']) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_move_file', $copy_files[$i]['from']); } --- 468,477 ---- if ( !$mod_io->make_dir(dirname($copy_files[$i]['to'])) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_mkdir_file', dirname($copy_files[$i]['to'])); } if ( !$mod_io->copy_file($copy_files[$i]['from'], $copy_files[$i]['to']) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_move_file', $copy_files[$i]['from']); } *************** *** 546,549 **** --- 546,553 ---- for( $k = 0, $copy_total = sizeof($copy_files); $k < $copy_total; $k++ ) { + if ( !file_exists($copy_files[$k]['from']) ) + { + em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_copy', $copy_files[$k]['from'], $copy_files[$k]['to']); + } $copy_actions[] = 'copy ' . $copy_files[$k]['from'] . ' to ' . $copy_files[$k]['to']; } *************** *** 557,561 **** if ( !$modder->open($phpbb_root_path . $target_file) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_open', $target_file); } display_mod_action('processed', $action, $target_file); --- 561,565 ---- if ( !$modder->open($phpbb_root_path . $target_file) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_open', $target_file); } display_mod_action('processed', $action, $target_file); *************** *** 568,572 **** if ( !$modder->find($actions_data['find']) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'find', $actions_data['find']); --- 572,576 ---- if ( !$modder->find($actions_data['find']) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'find', $actions_data['find']); *************** *** 595,599 **** if ( !$modder->in_line_find($inlines_data['in-line-find']) ) { ! em_handle_error(EM_ERR_CRITICAL, 'EM_Err_inline_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'in-line-find', $inlines_data['in-line-find']); --- 599,603 ---- if ( !$modder->in_line_find($inlines_data['in-line-find']) ) { ! em_trigger_error(EM_ERR_CRITICAL, 'EM_Err_inline_find', $actions_data['find'], $target_file); } display_mod_action('processed', 'in-line-find', $inlines_data['in-line-find']); |