mirror of
https://github.com/fnproject/fn.git
synced 2022-10-28 21:29:17 +03:00
Uses SetDefaults as it does in create too.
This commit is contained in:
@@ -39,9 +39,7 @@ func (s *Server) handleRouteUpdate(c *gin.Context) {
|
||||
wroute.Route.AppName = c.MustGet(api.AppName).(string)
|
||||
wroute.Route.Path = path.Clean(c.MustGet(api.Path).(string))
|
||||
|
||||
if wroute.Route.IdleTimeout == 0 {
|
||||
wroute.Route.IdleTimeout = 30
|
||||
}
|
||||
wroute.Route.SetDefaults()
|
||||
|
||||
if err := wroute.Validate(true); err != nil {
|
||||
log.WithError(err).Debug(models.ErrRoutesUpdate)
|
||||
|
||||
Reference in New Issue
Block a user