diff --git a/src/routes/events/[event_id]/(badges)/badges/[badge_id]/ae_comp__badge_print_controls.svelte b/src/routes/events/[event_id]/(badges)/badges/[badge_id]/ae_comp__badge_print_controls.svelte index bca86a56..be69be9f 100644 --- a/src/routes/events/[event_id]/(badges)/badges/[badge_id]/ae_comp__badge_print_controls.svelte +++ b/src/routes/events/[event_id]/(badges)/badges/[badge_id]/ae_comp__badge_print_controls.svelte @@ -225,6 +225,17 @@ async function handle_print_badge() { }; if (is_first_print) data_to_update.print_first_datetime = now; + // Offline or API unreachable: skip the PATCH and print immediately. + // Never block a physical print for a network issue — staff can correct the + // count manually in the Admin section after connectivity is restored. + if (!navigator.onLine || $ae_loc?.account_id === 'ghost') { + if (browser) window.print(); + print_status = 'error'; + await new Promise((r) => setTimeout(r, 4000)); + if (browser) window.location.href = `/events/${event_id}/badges`; + return; + } + try { const result = await events_func.update_ae_obj__event_badge({ api_cfg: $ae_api,