server updates (#566)

* server updates

- improved route create/update validation/defaults
- improved/added route test cases

* cleanup

* negative concurrency check
This commit is contained in:
Jordan Krage
2017-03-03 09:33:19 -06:00
committed by Seif Lotfy سيف لطفي
parent 8a9678e4af
commit 1d0ba54b35
7 changed files with 93 additions and 61 deletions

View File

@@ -22,7 +22,7 @@ func (s *Server) handleAppDelete(c *gin.Context) {
c.JSON(http.StatusInternalServerError, simpleError(ErrInternalServerError))
return
}
//TODO allow this? #528
if len(routes) > 0 {
log.WithError(err).Debug(models.ErrDeleteAppsWithRoutes)
c.JSON(http.StatusBadRequest, simpleError(models.ErrDeleteAppsWithRoutes))