RAZ-3032: Code tweaks
- Put in tweaks to make code more robust, cfparams, cfif's to check calcs etc