| ... | ... | @@ -307,11 +307,11 @@ fn fail(response: *http.Response, comptime err: string, args: anytype) !void { |
| 307 | 307 | try response.writer().print(err, args); |
| 308 | 308 | } |
| 309 | 309 | |
| 310 | | fn redirectUri(alloc: *std.mem.Allocator, request: http.Request, callbackPath: string) !string { |
| 310 | fn redirectUri(alloc: std.mem.Allocator, request: http.Request, callbackPath: string) !string { |
| 311 | 311 | return try std.fmt.allocPrint(alloc, "http://{s}{s}", .{ request.host().?, callbackPath }); |
| 312 | 312 | } |
| 313 | 313 | |
| 314 | | fn fixId(alloc: *std.mem.Allocator, id: json.Value) !string { |
| 314 | fn fixId(alloc: std.mem.Allocator, id: json.Value) !string { |
| 315 | 315 | return switch (id) { |
| 316 | 316 | .String => |v| return v, |
| 317 | 317 | .Int => |v| return try std.fmt.allocPrint(alloc, "{d}", .{v}), |
| ... | ... | @@ -327,7 +327,7 @@ fn fixId(alloc: *std.mem.Allocator, id: json.Value) !string { |
| 327 | 327 | const UrlValues = struct { |
| 328 | 328 | inner: std.StringArrayHashMap(string), |
| 329 | 329 | |
| 330 | | pub fn init(alloc: *std.mem.Allocator) UrlValues { |
| 330 | pub fn init(alloc: std.mem.Allocator) UrlValues { |
| 331 | 331 | return .{ |
| 332 | 332 | .inner = std.StringArrayHashMap(string).init(alloc), |
| 333 | 333 | }; |