fix(catchers): return appropriate http status for internal server errors
Signed-off-by: SphericalKat <amolele@gmail.com>
This commit is contained in:
		
							parent
							
								
									a0642019c2
								
							
						
					
					
						commit
						0e04aa2879
					
				@ -52,7 +52,7 @@ pub fn forbidden() -> status::Custom<Json<Value>> {
 | 
			
		||||
#[catch(500)]
 | 
			
		||||
pub fn internal_server_error() -> status::Custom<Json<Value>> {
 | 
			
		||||
    status::Custom(
 | 
			
		||||
        Status::NotFound,
 | 
			
		||||
        Status::InternalServerError,
 | 
			
		||||
        Json(json!({
 | 
			
		||||
            "err":"internal server error",
 | 
			
		||||
            "msg": "Something went wrong, try again"
 | 
			
		||||
 | 
			
		||||
		Loading…
	
		Reference in New Issue
	
	Block a user