const { shippingService } = require("../../helpers/shipping.service");

exports.getShippingFee = async (req, res, next) => {
  const { customerId } = req;
  const shippingDetails = await shippingService(customerId);

  if (shippingDetails.error) {
    return res.status(400).json({ success: false, message: shippingDetails.error });
  }
  res.status(200).json({ success: true, shipping_details: shippingDetails });
};
