Index: google_apis/google_api_keys.cc |
diff --git a/google_apis/google_api_keys.cc b/google_apis/google_api_keys.cc |
index fc4b54735b44042eb79c7845028b37020491ac63..4a530dc0099122e1d1709562d4408b1711c10b8b 100644 |
--- a/google_apis/google_api_keys.cc |
+++ b/google_apis/google_api_keys.cc |
@@ -185,7 +185,8 @@ class APIKeyCache { |
<< " with value " << key_value << " from environment variable."; |
} |
- if (command_line_switch && command_line->HasSwitch(command_line_switch)) { |
+ if (command_line_switch && |
+ command_line->HasStringSwitch(command_line_switch)) { |
key_value = command_line->GetSwitchValueASCII(command_line_switch); |
LOG(INFO) << "Overriding API key " << environment_variable_name |
<< " with value " << key_value << " from command-line switch."; |