phpBB

Code Changes

File: phpbb/install/module/update_filesystem/task/diff_files.php

  Unmodified   Added   Modified   Removed
Line 132Line 132
			$file_contents = array();

// Handle the special case when user created a file with the filename that is now new in the core

			$file_contents = array();

// Handle the special case when user created a file with the filename that is now new in the core

			$file_contents[0] = (file_exists($old_path . $filename)) ? file_get_contents($old_path . $filename) : '';



			if (file_exists($old_path . $filename))
{
$file_contents[0] = file_get_contents($old_path . $filename);


$filenames = array(
$this->phpbb_root_path . $filename,


$filenames = array(
$this->phpbb_root_path . $filename,

Line 167Line 169
			);

unset($diff);

			);

unset($diff);

 
			}
else
{
$new_file_content = file_get_contents($new_path . $filename);

if ($new_file_content === false)
{
$this->iohandler->add_error_message(array('FILE_DIFFER_ERROR_FILE_CANNOT_BE_READ', $files_to_diff));
unset($new_file_content );
throw new user_interaction_required_exception();
}

// Save new file content to cache
$this->cache->put(
'_file_' . md5($filename),
base64_encode($new_file_content)
);
unset($new_file_content);
}


$progress_count++;
$this->iohandler->set_progress('UPDATE_FILE_DIFF', $progress_count);


$progress_count++;
$this->iohandler->set_progress('UPDATE_FILE_DIFF', $progress_count);