Skip to content

Commit

Permalink
better error message for selfmodify if auth disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
kakwa committed Jul 5, 2015
1 parent 1a37cb2 commit 7241b6f
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion ldapcherry/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -881,7 +881,10 @@ def selfmodify(self, **params):
sess = cherrypy.session
user = str(sess.get(SESSION_KEY, None))
if self.auth_mode == 'none':
return "not available without authentication disabled"
return self.temp_error.render(is_admin=is_admin,
alert = 'warning',
message="Not accessible with authentication disabled."
)
if cherrypy.request.method.upper() == 'POST':
params = self._parse_params(params)
self._selfmodify(params)
Expand Down

0 comments on commit 7241b6f

Please sign in to comment.