@thyrith/momentkh 2.5.4 → 2.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/momentkh.js +2 -2
  2. package/package.json +1 -1
package/momentkh.js CHANGED
@@ -630,8 +630,8 @@ khNewYearMoments = constant.khNewYearMoments
630
630
  }
631
631
  let epochLerngSak = Moment(`17-04-${gregorianYear} ${info.timeOfNewYear.hour}:${info.timeOfNewYear.minute}`, 'DD-MM-YYYY H:m')
632
632
  let khEpoch = findLunarDate(epochLerngSak)
633
- let diffFromEpoch = (((khEpoch.month - 4) * 30) + khEpoch.day) -
634
- (((info.lunarDateLerngSak.month - 4) * 30) + info.lunarDateLerngSak.day)
633
+ let diffFromEpoch = (((khEpoch.month - 4) * 29) + khEpoch.day) -
634
+ (((info.lunarDateLerngSak.month - 4) * 29) + info.lunarDateLerngSak.day)
635
635
  let result = epochLerngSak.subtract(diffFromEpoch + numberNewYearDay - 1, 'day')
636
636
  // Caching
637
637
  Moment.khNewYearMoments[gregorianYear] = result.format('DD-MM-YYYY H:m')
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thyrith/momentkh",
3
- "version": "2.5.4",
3
+ "version": "2.5.5",
4
4
  "description": "Working on khmer calendar by implementting moment js",
5
5
  "license": "MIT",
6
6
  "type": "component",