1
0
Fork 0

fixed potential error

pull/41/head
everzet 2011-10-01 17:06:14 +03:00
parent 1cca62dc97
commit d5ba884f8b
1 changed files with 5 additions and 1 deletions

View File

@ -43,7 +43,11 @@ class FilesystemRepository extends ArrayRepository implements WritableRepository
{
parent::initialize();
$packages = $this->file->read();
$packages = null;
if ($this->file->exists()) {
$packages = $this->file->read();
}
if (is_array($packages)) {
$loader = new ArrayLoader();
foreach ($packages as $package) {