mirror of
https://github.com/arthur-pbty/xiao.git
synced 2026-06-25 22:32:50 +02:00
Add years to days since
This commit is contained in:
@@ -37,6 +37,6 @@ module.exports = class DaysSinceCommand extends Command {
|
|||||||
const past = new Date(`${month}/${day}/${year}`);
|
const past = new Date(`${month}/${day}/${year}`);
|
||||||
const pastFormat = moment.utc(past).format('dddd, MMMM Do, YYYY');
|
const pastFormat = moment.utc(past).format('dddd, MMMM Do, YYYY');
|
||||||
const time = moment.duration(now - past);
|
const time = moment.duration(now - past);
|
||||||
return msg.say(`There have been ${time.format('M [months and] d [days]')} since ${pastFormat}!`);
|
return msg.say(`There have been ${time.format('Y [years,] M [months and] d [days]')} since ${pastFormat}!`);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user