moved error_message up