@zeyolabs/shopping 2026.11.47 → 2026.11.49

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.
@@ -111,7 +111,8 @@ export const FulfilmentManager = {
111
111
  async saveDetails(number: string, details: OrderDetails) {
112
112
  const db = shopping().db();
113
113
  if (details.shippingService) {
114
- const known = await new ShippingService(db).services();
114
+ const shipping = new ShippingService(db);
115
+ const known = await shipping.services();
115
116
  if (!known.some((s) => s.service === details.shippingService))
116
117
  throw Error400('Choose one of the shop’s postage services.');
117
118
  }
@@ -132,7 +133,8 @@ export const FulfilmentManager = {
132
133
 
133
134
  /** Postage services the admin can pick when correcting an order. */
134
135
  shippingServices() {
135
- return new ShippingService(shopping().db()).services();
136
+ const shipping = new ShippingService(shopping().db());
137
+ return shipping.services();
136
138
  },
137
139
 
138
140
  /**
@@ -72,8 +72,9 @@ export class FulfilmentService {
72
72
  ]);
73
73
  if (!address) return undefined;
74
74
  const productIds = items.flatMap((item) => (item.productId === null ? [] : [item.productId]));
75
+ const coverService = new CoverService(this.db);
75
76
  const [covers, estimatedWeightGrams] = await Promise.all([
76
- new CoverService(this.db).covers(productIds),
77
+ coverService.covers(productIds),
77
78
  this.estimateWeight(items),
78
79
  ]);
79
80
  return {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zeyolabs/shopping",
3
- "version": "2026.11.47",
3
+ "version": "2026.11.49",
4
4
  "description": "Shop and order fulfilment for SvelteKit 3 on Cloudflare: catalogue, basket, Stripe Checkout, orders, Royal Mail Click & Drop, order emails, packing, pages and admin.",
5
5
  "type": "module",
6
6
  "license": "UNLICENSED",
@@ -68,7 +68,7 @@
68
68
  "@eslint/js": "10.0.1",
69
69
  "@sveltejs/kit": "3.2.0",
70
70
  "@zeyolabs/kit": "2026.11.42",
71
- "@zeyolabs/ui": "2026.11.40",
71
+ "@zeyolabs/ui": "2026.11.41",
72
72
  "drizzle-orm": "0.45.4",
73
73
  "eslint": "10.15.0",
74
74
  "eslint-config-prettier": "10.1.8",