fix int overflow
This commit is contained in:
parent
30f0aa51b6
commit
ff1bb89449
@ -185,7 +185,7 @@ func (uf *UploadForm) IntoResource() *services.Resource {
|
|||||||
Name: uf.Name.Value,
|
Name: uf.Name.Value,
|
||||||
Editor: uf.Editor.Value,
|
Editor: uf.Editor.Value,
|
||||||
Authors: uf.Authors.Value,
|
Authors: uf.Authors.Value,
|
||||||
Year: uint16(uf.Year.Value),
|
Year: uf.Year.Value,
|
||||||
Keywords: nil,
|
Keywords: nil,
|
||||||
Content: bytes.NewBuffer(uf.File.Value.content),
|
Content: bytes.NewBuffer(uf.File.Value.content),
|
||||||
}
|
}
|
||||||
|
|||||||
@ -80,7 +80,7 @@ type Resource struct {
|
|||||||
Description *string
|
Description *string
|
||||||
Editor string
|
Editor string
|
||||||
Authors []string
|
Authors []string
|
||||||
Year uint16
|
Year int
|
||||||
Keywords []string
|
Keywords []string
|
||||||
Content *bytes.Buffer
|
Content *bytes.Buffer
|
||||||
Path string
|
Path string
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user