changed error code to const