Only call error callback once when api key is not set