chore: build

This commit is contained in:
2026-06-11 20:22:52 +02:00
parent b810248d74
commit 7f0b3ff29b
@@ -795,7 +795,8 @@ function CentralRewardSection({
}) { }) {
const { width: screenWidth } = useWindowDimensions(); const { width: screenWidth } = useWindowDimensions();
const enabled = !!reward; const enabled = !!reward;
const r = reward ?? EMPTY_REWARD; const rawR = reward ?? EMPTY_REWARD;
const r: PointsReward = { ...rawR, category_configs: rawR.category_configs ?? [] };
const update = (patch: Partial<PointsReward>) => const update = (patch: Partial<PointsReward>) =>
onChange({ ...r, ...patch }); onChange({ ...r, ...patch });
@@ -1090,10 +1091,13 @@ export default function SettingsScreen() {
delivery_schedule: s.delivery_schedule ?? DEFAULT_DELIVERY_SCHEDULE, delivery_schedule: s.delivery_schedule ?? DEFAULT_DELIVERY_SCHEDULE,
postal_zones: s.postal_zones ?? DEFAULT_POSTAL_ZONES, postal_zones: s.postal_zones ?? DEFAULT_POSTAL_ZONES,
delivery_mode: { delivery_mode: {
...(s.delivery_mode ?? { mode: "single" }), mode: "single" as const,
...(s.delivery_mode ?? {}),
category_routes: s.delivery_mode?.category_routes ?? [], category_routes: s.delivery_mode?.category_routes ?? [],
}, },
points_reward: s.points_reward ?? null, points_reward: s.points_reward
? { ...s.points_reward, category_configs: s.points_reward.category_configs ?? [] }
: null,
}); });
} }
if (categoriesRes) { if (categoriesRes) {