Fix error handling in access