fix: add json tags

This commit is contained in:
Derrick Hammer 2024-01-18 12:15:47 -05:00
parent cf168f8e4d
commit a9834a81d3
Signed by: pcfreak30
GPG Key ID: C997C339BE476FF2
2 changed files with 7 additions and 7 deletions

View File

@ -17,11 +17,11 @@ var (
type WebAppMetadata struct {
BaseMetadata
Name string
TryFiles []string
ErrorPages map[int]string
ExtraMetadata ExtraMetadata
Paths map[string]WebAppMetadataFileReference
Name string `json:"name"`
TryFiles []string `json:"tryFiles"`
ErrorPages map[int]string `json:"errorPages"`
ExtraMetadata ExtraMetadata `json:"extraMetadata"`
Paths map[string]WebAppMetadataFileReference `json:"paths"`
}
func NewWebAppMetadata(name string, tryFiles []string, extraMetadata ExtraMetadata, errorPages map[int]string, paths map[string]WebAppMetadataFileReference) *WebAppMetadata {

View File

@ -3,8 +3,8 @@ package metadata
import "git.lumeweb.com/LumeWeb/libs5-go/encoding"
type WebAppMetadataFileReference struct {
ContentType string
Cid *encoding.CID
ContentType string `json:"contentType"`
Cid *encoding.CID `json:"cid"`
}
func NewWebAppMetadataFileReference(cid *encoding.CID, contentType string) *WebAppMetadataFileReference {