resolve 500 error