fixed a bug that caused a php error when a readme file was not a regular file

This commit is contained in:
hyung-hwan 2015-06-29 09:50:11 +00:00
parent 29354a812c
commit aa0e52e8dd

View File

@ -128,7 +128,7 @@ class Code extends Controller
if (strlen($rf) > 0) if (strlen($rf) > 0)
{ {
$readme = $this->subversion->getFile ($projectid, $path . '/' . $rf, $rev); $readme = $this->subversion->getFile ($projectid, $path . '/' . $rf, $rev);
if ($readme !== FALSE) if ($readme !== FALSE && $readme['type'] == 'file')
{ {
$data['readme_text'] = $readme['content']; $data['readme_text'] = $readme['content'];
$data['readme_file'] = $rf; $data['readme_file'] = $rf;