>A space is required after an if statement

You mean empty line?
>'$clean_up' should be '$cleanUp'

I will fix that, but all other variables in this file is in '$clean_up' style