mirror of
https://github.com/kovetskiy/mark.git
synced 2026-03-19 09:07:36 +08:00
http.DetectContentType was called with potentially nil/empty contents when ReadFile failed; the error was only checked afterward. Move the error check immediately after ReadFile so bad data is never used. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>