From 1e31b71afd1ead4644e99df6838a55481176e09a Mon Sep 17 00:00:00 2001 From: Nathan Reiner Date: Sun, 23 Nov 2025 16:41:43 +0100 Subject: add fonts and create-user endpoint --- src/routes/handler-info.zig | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/routes/handler-info.zig') diff --git a/src/routes/handler-info.zig b/src/routes/handler-info.zig index 5183628..9e10bd5 100644 --- a/src/routes/handler-info.zig +++ b/src/routes/handler-info.zig @@ -122,6 +122,11 @@ pub fn handle( .value = context.response.headers.content_type }); + try headers.append(allocator, .{ + .name = "Service-Worker-Allowed", + .value = "/", + }); + if (context.response.headers.fingerprint) |auth_token| { var value = std.Io.Writer.Allocating.init(arena.allocator()); @@ -176,7 +181,10 @@ fn HandlerWrapper(T: type, name: []const u8) type { ctx.allocator, writer.written(), .{}, - ) catch return error.BadRequest; + ) catch |err| { + log.warn("failed to parse JSON {}", .{err}); + return error.BadRequest; + }; break :args .{ ctx, body }; } else { @compileError("invalid amount of arguments for request function"); -- cgit v1.2.3-70-g09d2