Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #6670 from SimenB/patch-1
Use 2-digit format for day and month in "built at" output
  • Loading branch information
sokra committed Mar 6, 2018
2 parents c54df36 + bb2320c commit edbb6f6
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/Stats.js
Expand Up @@ -736,7 +736,13 @@ class Stats {
if (typeof obj.builtAt === "number") {
const builtAtDate = new Date(obj.builtAt);
colors.normal("Built at: ");
colors.normal(builtAtDate.toLocaleDateString());
colors.normal(
builtAtDate.toLocaleDateString({
day: "2-digit",
month: "2-digit",
year: "numeric"
})
);
colors.normal(" ");
colors.bold(builtAtDate.toLocaleTimeString());
newline();
Expand Down

0 comments on commit edbb6f6

Please sign in to comment.