Differential D21864 Diff 52157 src/applications/diffusion/query/rawdiff/DiffusionGitRawDiffQuery.php
Changeset View
Changeset View
Standalone View
Standalone View
src/applications/diffusion/query/rawdiff/DiffusionGitRawDiffQuery.php
Show All 29 Lines | if ($against === null) { | ||||
if (strlen(trim($parents))) { | if (strlen(trim($parents))) { | ||||
$against = $commit.'^'; | $against = $commit.'^'; | ||||
} else { | } else { | ||||
$against = ArcanistGitAPI::GIT_MAGIC_ROOT_COMMIT; | $against = ArcanistGitAPI::GIT_MAGIC_ROOT_COMMIT; | ||||
} | } | ||||
} | } | ||||
$path = $drequest->getPath(); | $path = $drequest->getPath(); | ||||
if (!strlen($path)) { | if ($path === null || !strlen($path)) { | ||||
$path = '.'; | $path = '.'; | ||||
} | } | ||||
return $repository->getLocalCommandFuture( | return $repository->getLocalCommandFuture( | ||||
'diff %Ls %s %s -- %s', | 'diff %Ls %s %s -- %s', | ||||
$options, | $options, | ||||
gitsprintf('%s', $against), | gitsprintf('%s', $against), | ||||
gitsprintf('%s', $commit), | gitsprintf('%s', $commit), | ||||
$path); | $path); | ||||
} | } | ||||
} | } |