Added if function_exists to stop error

I was getting an error on my localhost, function was not found.