fix(delivey): change StatusCreated to StatusOk where there is nothing created

This commit is contained in:
Erfan Mohammadi 2024-04-28 15:17:24 +03:30 committed by Alireza Mokhtari Garakani
parent 5f43b90b2b
commit 47649e9952
5 changed files with 5 additions and 5 deletions

View File

@ -36,5 +36,5 @@ func (h Handler) Accept(c echo.Context) error {
return echo.NewHTTPError(code, msg)
}
return c.JSON(http.StatusCreated, resp)
return c.JSON(http.StatusOK, resp)
}

View File

@ -32,5 +32,5 @@ func (h Handler) GetAll(c echo.Context) error {
return echo.NewHTTPError(code, msg)
}
return c.JSON(http.StatusCreated, resp)
return c.JSON(http.StatusOK, resp)
}

View File

@ -36,5 +36,5 @@ func (h Handler) Reject(c echo.Context) error {
return echo.NewHTTPError(code, msg)
}
return c.JSON(http.StatusCreated, resp)
return c.JSON(http.StatusOK, resp)
}

View File

@ -28,5 +28,5 @@ func (h Handler) Get(c echo.Context) error {
return echo.NewHTTPError(code, msg)
}
return c.JSON(http.StatusCreated, resp)
return c.JSON(http.StatusOK, resp)
}

View File

@ -21,5 +21,5 @@ func (h Handler) GetAll(c echo.Context) error {
return echo.NewHTTPError(code, msg)
}
return c.JSON(http.StatusCreated, resp)
return c.JSON(http.StatusOK, resp)
}