mirror of
https://we.phorge.it/source/phorge.git
synced 2024-11-26 16:52:41 +01:00
parse with %s as number_format()
returns stirng
Summary: `number_format()` returns a string, so if passed a number greater than 999 by default it will add commas, which parsed by %d will only return the 1000's delimter. ```echo sprintf("%d", number_format(1000)); // Outputs 1 echo sprintf("%s", number_format(1000)); // Outputs 1,000 Test Plan: Looked at repos with over 999 commits. Reviewers: epriestley, chad Reviewed By: epriestley CC: aran, Korvin Differential Revision: https://secure.phabricator.com/D5913
This commit is contained in:
parent
c5929e376c
commit
9c87ba8b09
1 changed files with 2 additions and 2 deletions
|
@ -94,7 +94,7 @@ final class DiffusionHomeController extends DiffusionController {
|
||||||
'callsign' => $repository->getCallsign(),
|
'callsign' => $repository->getCallsign(),
|
||||||
'action' => 'history',
|
'action' => 'history',
|
||||||
)),
|
)),
|
||||||
pht('%d Commits', number_format($size)));
|
pht('%s Commits', new PhutilNumber($size)));
|
||||||
}
|
}
|
||||||
|
|
||||||
$lint_count = '';
|
$lint_count = '';
|
||||||
|
@ -110,7 +110,7 @@ final class DiffusionHomeController extends DiffusionController {
|
||||||
'action' => 'lint',
|
'action' => 'lint',
|
||||||
)),
|
)),
|
||||||
),
|
),
|
||||||
pht('%d Lint Messages', number_format($lint_branches[$branch])));
|
pht('%s Lint Messages', new PhutilNumber($lint_branches[$branch])));
|
||||||
}
|
}
|
||||||
|
|
||||||
$datetime = '';
|
$datetime = '';
|
||||||
|
|
Loading…
Reference in a new issue