Skip to content

Commit

Permalink
RedirectIndex should be invisible
Browse files Browse the repository at this point in the history
  • Loading branch information
Brian Peterson committed Aug 29, 2019
1 parent 5fe6eba commit 8014820
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion flask_secure_admin/security/indexes.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ class SecureRedirectIndex(AdminIndexView):

def __init__(self, index_endpoint, *args, **kwargs):
self.index_endpoint = index_endpoint
self.is_visible = lambda: False
super(SecureRedirectIndex, self).__init__(*args, **kwargs)

@expose('/')
Expand All @@ -27,7 +28,6 @@ def index(self):
is not the default value. """
if self.index_endpoint and \
self.index_endpoint != DEFAULT_INDEX_ENDPOINT:
self.is_visible = lambda: False
return redirect(url_for(self.index_endpoint, _external=True))
else:
return self.render(DEFAULT_INDEX_TEMPLATE)

0 comments on commit 8014820

Please sign in to comment.