Lots of checks and changes