Add TODO
This commit is contained in:
parent
19ce10e49e
commit
938be81c45
@ -437,10 +437,11 @@ func (s *Server) TokenizeHandler(c *gin.Context) {
|
|||||||
|
|
||||||
opts, err := modelOptions(model, req.Options)
|
opts, err := modelOptions(model, req.Options)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
if errors.Is(err, api.ErrInvalidOpts) {
|
// TODO: handle specific errors
|
||||||
c.JSON(http.StatusBadRequest, gin.H{"error": err.Error()})
|
// if errors.Is(err, api.ErrInvalidOpts) {
|
||||||
return
|
// c.JSON(http.StatusBadRequest, gin.H{"error": err.Error()})
|
||||||
}
|
// return
|
||||||
|
// }
|
||||||
c.JSON(http.StatusInternalServerError, gin.H{"error": err.Error()})
|
c.JSON(http.StatusInternalServerError, gin.H{"error": err.Error()})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user