Added error checking for missing params