added a check if Google API parameters are correctly set