Refactor cvr.class.php

- Remove unecessary code
- Add return statement so the script won't proceed on error
- Rename methods to more logical names