Skip to content

Commit

Permalink
subsonic: make homepageURL parameter optional
Browse files Browse the repository at this point in the history
By the https://opensubsonic.netlify.app/docs/endpoints/createinternetradiostation/ the `homepageURL` is not requirement option
  • Loading branch information
archekb authored Aug 2, 2023
1 parent 5fb9c49 commit 8f05f33
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion server/ctrlsubsonic/handlers_internet_radio.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ func (c *Controller) ServeCreateInternetRadioStation(r *http.Request) *spec.Resp
return spec.NewError(10, "no name provided: %v", err)
}
homepageURL, err := params.Get("homepageUrl")
if err == nil {
if err == nil && homepageURL != "" {
if _, err := url.ParseRequestURI(homepageURL); err != nil {
return spec.NewError(70, "bad homepage URL provided: %v", err)
}
Expand Down

0 comments on commit 8f05f33

Please sign in to comment.