@bytebrand/export-cars 1.21.64 → 1.21.65

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bytebrand/export-cars",
3
- "version": "1.21.64",
3
+ "version": "1.21.65",
4
4
  "description": "",
5
5
  "author": "bytebrand",
6
6
  "license": "UNLICENSED",
@@ -401,8 +401,11 @@ export class GoogleTransformer {
401
401
  if (!timestamp) {
402
402
  timestamp = Math.round(new Date().getTime() / 1000);
403
403
  }
404
+
404
405
  if (!car.mainData.firstRegistration || this.monthDiffLess(car, 8)) {
405
- timestamp = moment().subtract(9, 'months').unix()
406
+ const currentDate = new Date();
407
+ currentDate.setMonth(currentDate.getMonth() - 9); // Відняти 9 місяців
408
+ timestamp = Math.round(currentDate.getTime() / 1000); // Перетворити на секунди
406
409
  }
407
410
 
408
411
  const date = new Date(timestamp * 1000);