Fix warnings generated by go-staticcheck

This commit is contained in:
Alf Sebastian Houge
2022-04-28 17:47:35 +02:00
parent 24105dbaaf
commit 0b715ef840
6 changed files with 18 additions and 20 deletions

View File

@@ -397,7 +397,7 @@ func deleteVehicle(c *gin.Context) {
return
}
if !canDelete {
c.JSON(http.StatusUnprocessableEntity, common.NewError("shareVehicle", errors.New("You are not allowed to delete this vehicle.")))
c.JSON(http.StatusUnprocessableEntity, common.NewError("shareVehicle", errors.New("you are not allowed to delete this vehicle")))
return
}
err = service.DeleteVehicle(searchByIdQuery.Id)