Skip to content

Commit

Permalink
Fix the code miss to show the correct error messages
Browse files Browse the repository at this point in the history
In keystone/common/ldap/core.py I found the code like below:

 86 raise ValueError(_(
 87 'Invalid LDAP TLS certs option: %(option). '
 88 'Choose one of: %(options)s') % {

The code "%(option)" in line 87 should be fixed to "%(option)s" to
show the correct error messages when the exception happens.
This patch fixes this error.

Fixes bug #1220601

Change-Id: I87328080facd4d9b1349a677c00a93d118993538
  • Loading branch information
Haiwei Xu committed Sep 4, 2013
1 parent fb28e51 commit 356d246
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion keystone/common/ldap/core.py
Expand Up @@ -84,7 +84,7 @@ def parse_tls_cert(opt):
return LDAP_TLS_CERTS[opt]
except KeyError:
raise ValueError(_(
'Invalid LDAP TLS certs option: %(option). '
'Invalid LDAP TLS certs option: %(option)s. '
'Choose one of: %(options)s') % {
'option': opt,
'options': ', '.join(LDAP_TLS_CERTS.keys())})
Expand Down

0 comments on commit 356d246

Please sign in to comment.