Use [] where a value is required

The use of .get() implies that having no value, or None is ok,
but in the case that's fixed here, a value of None would result
in an error, so [] is correct to use here.

Change-Id: I47113121c10c2d0682daf40eb616b379e2d212e8
This commit is contained in:
Brant Knudson 2015-04-26 10:32:15 -05:00
parent 8f35d0ca27
commit 9465f9e5a4

View File

@ -65,7 +65,7 @@ def load_auth_methods():
plugin_name = driver.method
else:
plugin_name = plugin
plugin_class = CONF.auth.get(plugin)
plugin_class = CONF.auth[plugin]
driver = importutils.import_object(plugin_class)
if plugin_name in AUTH_METHODS:
raise ValueError(_('Auth plugin %(plugin)s is requesting '