add set background and icon of hub functions
This commit is contained in:
@@ -15,6 +15,8 @@ const (
|
||||
file
|
||||
avatar
|
||||
profileBg
|
||||
hubIcon
|
||||
hubBackground
|
||||
)
|
||||
|
||||
func validCheckWithResponseOnFail(response http.ResponseWriter, request *http.Request, pt bodyLimit) bool {
|
||||
@@ -22,10 +24,19 @@ func validCheckWithResponseOnFail(response http.ResponseWriter, request *http.Re
|
||||
switch pt {
|
||||
case file:
|
||||
maxSize = int64(config.MaxRequestWithFileBytes)
|
||||
break
|
||||
case avatar:
|
||||
maxSize = int64(config.MaxRequestWithAvatarBytes)
|
||||
break
|
||||
case profileBg:
|
||||
maxSize = int64(config.MaxRequestWithProfileBgBytes)
|
||||
break
|
||||
case hubIcon:
|
||||
maxSize = int64(config.MaxRequestWithHubIconBytes)
|
||||
break
|
||||
case hubBackground:
|
||||
maxSize = int64(config.MaxRequestWithHubBackgroundBytes)
|
||||
break
|
||||
default:
|
||||
maxSize = int64(config.MaxRequestBytes)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user