diff options
Diffstat (limited to 'models/repo/release.go')
-rw-r--r-- | models/repo/release.go | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/models/repo/release.go b/models/repo/release.go index a00585111e..191475d541 100644 --- a/models/repo/release.go +++ b/models/repo/release.go @@ -133,6 +133,11 @@ func (r *Release) HTMLURL() string { return r.Repo.HTMLURL() + "/releases/tag/" + util.PathEscapeSegments(r.TagName) } +// APIUploadURL the api url to upload assets to a release. release must have attributes loaded +func (r *Release) APIUploadURL() string { + return r.APIURL() + "/assets" +} + // Link the relative url for a release on the web UI. release must have attributes loaded func (r *Release) Link() string { return r.Repo.Link() + "/releases/tag/" + util.PathEscapeSegments(r.TagName) |