Clean up and extra checks
Cleaning up a bit