Browse Source

fix(core): Ensure `surcharges` relation is loaded in assignToChannels (#3812)

Casper Iversen 4 months ago
parent
commit
9d58978d96
1 changed files with 1 additions and 1 deletions
  1. 1 1
      packages/core/src/service/services/channel.service.ts

+ 1 - 1
packages/core/src/service/services/channel.service.ts

@@ -187,7 +187,7 @@ export class ChannelService {
         // so that this join could be done prior to invoking this method.
         // so that this join could be done prior to invoking this method.
         // TODO: overload the assignToChannels method to allow it to take an entity instance
         // TODO: overload the assignToChannels method to allow it to take an entity instance
         if (entityType === (Order as any)) {
         if (entityType === (Order as any)) {
-            relations.push('lines', 'shippingLines');
+            relations.push('lines', 'shippingLines', 'surcharges');
         }
         }
         const entity = await this.connection.getEntityOrThrow(ctx, entityType, entityId, {
         const entity = await this.connection.getEntityOrThrow(ctx, entityType, entityId, {
             loadEagerRelations: false,
             loadEagerRelations: false,