Simplify output buffering code

No need to use both ob_get_contents() and ob_end_clean() when you can just use ob_get_clean().