Remove unnecessary check

This commit is contained in:
TwiN 2021-12-14 23:26:18 -05:00
parent 8676b83fe3
commit 1777d69495

View File

@ -40,7 +40,7 @@ func CreateRouter(staticFolder string, securityConfig *security.Config, uiConfig
} }
func secureIfNecessary(securityConfig *security.Config, handler http.HandlerFunc) http.HandlerFunc { func secureIfNecessary(securityConfig *security.Config, handler http.HandlerFunc) http.HandlerFunc {
if securityConfig != nil && securityConfig.IsValid() { if securityConfig != nil {
return security.Handler(handler, securityConfig) return security.Handler(handler, securityConfig)
} }
return handler return handler