From aefe9efaaab9d5b09bff95ec4d7f0e9ebf50362a Mon Sep 17 00:00:00 2001 From: Derrick Hammer Date: Fri, 1 Mar 2024 10:30:08 -0500 Subject: [PATCH] fix: export struct and add json tags --- api/s5/s5.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/api/s5/s5.go b/api/s5/s5.go index 4c00bba..45b1e0a 100644 --- a/api/s5/s5.go +++ b/api/s5/s5.go @@ -857,8 +857,8 @@ func (s *S5API) getManifestCids(cid *encoding.CID) ([]*encoding.CID, error) { func (s *S5API) accountPinManifest(jc jape.Context, userId uint, cid *encoding.CID) { type pinResult struct { - success bool - error error + Success bool `json:"success"` + Error error `json:"error,omitempty"` } type pinQueueResult struct { @@ -919,8 +919,8 @@ func (s *S5API) accountPinManifest(jc jape.Context, userId uint, cid *encoding.C } results[b64] = pinResult{ - success: ret.success, - error: ret.error, + Success: ret.success, + Error: ret.error, } received++