I just noticed, only the last line needs to be indented like this to silence the error... odd.