Cleanup - unused files / unused exports / duplicate exports
[ProtonMail-WebClient.git] / packages / shared / lib / date-fns-utc / differenceInCalendarDays.ts
blob1295607c09efeeae2ae89d6e7f79000a7ea34516
1 import { DAY } from '@proton/shared/lib/constants';
3 import startOfDay from './startOfDay';
5 const differenceInCalendarDays = (left: Date, right: Date) => {
6     const startOfDayLeft = startOfDay(left);
7     const startOfDayRight = startOfDay(right);
9     const diff = startOfDayLeft.getTime() - startOfDayRight.getTime();
11     return Math.round(diff / DAY);
14 export default differenceInCalendarDays;