Resolve errors when api key is empty