@bytebrand/export-cars 1.26.4 → 1.26.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bytebrand/export-cars",
3
- "version": "1.26.4",
3
+ "version": "1.26.5",
4
4
  "description": "",
5
5
  "author": "bytebrand",
6
6
  "license": "UNLICENSED",
@@ -178,8 +178,6 @@ export class ImagesService {
178
178
  }
179
179
 
180
180
  async getMarketingImages(carId: string, images: ImboImageResponseInterface[], ignoreDefImages: boolean): Promise<string[]> {
181
- const imageUrl = this.configService.config.marketingImageUrl;
182
-
183
181
  const transformedImages = this.transformImagesArrayIntoObject(images);
184
182
  // fbMarketingImageId is a hardcoded per-environment id in config.ts and has drifted from
185
183
  // the real meta_aia config at least once (dev's id pointed at a stale, never-populated "fb"
@@ -193,6 +191,14 @@ export class ImagesService {
193
191
  return ignoreDefImages ? [] : [...this.DEFAULT_IMAGES];
194
192
  }
195
193
 
194
+ // marketingImageUrl (config.ts environmentConfig[env].imageUrl) points at /cache_test on
195
+ // dev — a leftover from the old "fb" channel, not where image-generator publishes meta_aia
196
+ // composites (always under /generated_images on both dev and prod). Build the meta_aia base
197
+ // from the plain image host instead of trusting that per-env path.
198
+ const imageUrl = config.channelCode === 'meta_aia'
199
+ ? `${this.configService.config.imageUrl}/generated_images`
200
+ : this.configService.config.marketingImageUrl;
201
+
196
202
  const marketingImageConfigs = config.marketingImages.map(i => ({ marketingImageCodes: i.imageCodes }));
197
203
 
198
204
  if (this.configService.config.exportType === ExportType.FB && !this.hasLoggedMarketingImageDebug) {