Skip to content

Fixed findShipment bug in getLabels

Loic Huder requested to merge fix-label-generation into master

This is because getLabels was using the helper method findShipmentById that returns a mongoose Document with the addresses populated and sanitized since !267 (merged). getLabels was expecting a Query to call populate.

Fixed by changing helper.findShipmentById to Shipment.findById (returns a Query) as we don't need the populated addresses anyway for the label generation.

Merge request reports

Loading