From bf15faf33ffaecea3f6b86aee2a6500da775e92b Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Wed, 24 Jan 2024 19:10:19 -0500 Subject: [PATCH] feat: need else on hash check --- api/s5/http.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/api/s5/http.go b/api/s5/http.go index 14a66c8..0341ca0 100644 --- a/api/s5/http.go +++ b/api/s5/http.go @@ -1299,9 +1299,10 @@ func (h *HttpHandler) DownloadFile(jc jape.Context) { } hashBytes = hashDecoded.HashBytes() - } + } else { - hashBytes = cidDecoded.Hash.HashBytes() + hashBytes = cidDecoded.Hash.HashBytes() + } file := storage.NewFile(hashBytes, h.portal.Storage())