fix: updated repository field in Package struct (#647)

The definition for `Package` in the most recent api switch the
repository field from a string to a `Repository`.
Without this fix api calls like ListPackages will fail to deserialize
the response.

Co-authored-by: diogo464 <diogo464@protonmail.com>
Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-on: https://gitea.com/gitea/go-sdk/pulls/647
Reviewed-by: Lunny Xiao <xiaolunwen@gmail.com>
Reviewed-by: John Olheiser <jolheiser@noreply.gitea.com>
Co-authored-by: diogo464 <diogo464@noreply.gitea.com>
Co-committed-by: diogo464 <diogo464@noreply.gitea.com>
This commit is contained in:
diogo464 2024-01-29 05:38:16 +00:00 committed by Lunny Xiao
parent 53f735b911
commit 5d0143e4e7

View file

@ -16,7 +16,7 @@ type Package struct {
// the package's owner
Owner User `json:"owner"`
// the repo this package belongs to (if any)
Repository *string `json:"repository"`
Repository *Repository `json:"repository"`
// the package's creator
Creator User `json:"creator"`
// the type of package: