Skip to content

Commit c1d3bc6

Browse files
committed
Fixed previous commit
1 parent fe90056 commit c1d3bc6

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/Gitonomy/Git/Commit.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -264,7 +264,10 @@ public function getLastModification($path)
264264
$path = StringHelper::substr($path, 1);
265265
}
266266

267-
$path = $this->repository->getWorkingDir().'/'.$path;
267+
if ($getWorkingDir = $this->repository->getWorkingDir()) {
268+
$path = $getWorkingDir.'/'.$path;
269+
}
270+
268271
$result = $this->repository->run('log', array('--format=%H', '-n', 1, $this->hash, '--', $path));
269272

270273
return $this->repository->getCommit(trim($result));

0 commit comments

Comments
 (0)