Skip to content

Commit

Permalink
Fixes becouse of translation
Browse files Browse the repository at this point in the history
  • Loading branch information
blagojabozinovski committed Aug 22, 2023
1 parent 0fe4a83 commit e2848cd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion ckanext/password_policy/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def user_custom_password_validator(key, data, errors, context):
elif value == '':
pass
elif not valid_pass['password_ok']:
errors[('password',)].append('Your password must be 12 characters or longer and contain uppercase, lowercase, digit and special character')
errors[('password',)].append(_('Your password must be 12 characters or longer and contain uppercase, lowercase, digit and special character'))


class PasswordPolicyPlugin(plugins.SingletonPlugin):
Expand Down
2 changes: 1 addition & 1 deletion ckanext/password_policy/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ def _get_form_password(self):
valid_pass = helper.custom_password_check(password1)
if valid_pass['password_ok']==False:
raise ValueError(
_(f'Your password must be 12 characters or longer and contain uppercase, lowercase, digit and special character'))
_('Your password must be 12 characters or longer and contain uppercase, lowercase, digit and special character'))
elif password1 != password2:
raise ValueError(
_(u'The passwords you entered'
Expand Down

0 comments on commit e2848cd

Please sign in to comment.