From 6ca18b057bfab60792303133ef221d8a86ea5687 Mon Sep 17 00:00:00 2001 From: Adriano Cunha <35786489+adrcunha@users.noreply.github.com> Date: Thu, 2 May 2024 00:50:08 -0700 Subject: [PATCH] Fix sending favicon in http_server (#21) `favicon` is now an array, and `end()` expects a Buffer or String. --- http_server.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/http_server.ts b/http_server.ts index 6ec8242..599e1b3 100644 --- a/http_server.ts +++ b/http_server.ts @@ -86,7 +86,7 @@ export const serveHttp = (opts: opt, port: number, with_audio: boolean) => { if (req.url.startsWith("/favicon.ico")) { res.setHeader("Content-Type", "image/x-icon"); res.setHeader("Content-Encoding", "gzip"); - res.end(favicon); + res.end(Buffer.from(favicon)); return; }