added ircs support
Cette révision appartient à :
Parent
b3ade9f273
révision
665c6e3116
1 fichiers modifiés avec 1 ajouts et 1 suppressions
|
@ -124,7 +124,7 @@ func (f *UploadForm) ExtractInfo(r *http.Request) error {
|
|||
}
|
||||
if f.WebsiteLink != "" {
|
||||
// WebsiteLink
|
||||
urlRegexp, _ := regexp.Compile(`^(https?:\/\/|irc:\/\/)?([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w \.-]*)*\/?$`)
|
||||
urlRegexp, _ := regexp.Compile(`^(https?:\/\/|ircs?:\/\/)?([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w \.-]*)*\/?$`)
|
||||
if !urlRegexp.MatchString(f.WebsiteLink) {
|
||||
return ErrInvalidWebsiteLink
|
||||
}
|
||||
|
|
Référencer dans un nouveau ticket