diff options
author | deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com> | 2021-06-07 08:29:43 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-06-07 08:29:43 +0000 |
commit | 47ac6500a959f04d5b8eeffe40499e6cefc8156c (patch) | |
tree | ebf028184e6cdda656e885a0fd6284ba547979a9 /app/views/admin.py | |
parent | 11a2e1c778cf4b2ea958b6bdd7868c8604d45df2 (diff) |
Format code with black
This commit fixes the style issues introduced in 11a2e1c according to the output
from black.
Details: https://deepsource.io/gh/navanchauhan/SaaS-in-a-Flask/transform/5a6278fb-7606-43ba-b4b5-8c059152a84c/
Diffstat (limited to 'app/views/admin.py')
-rw-r--r-- | app/views/admin.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/app/views/admin.py b/app/views/admin.py index 8588e87..56014a0 100644 --- a/app/views/admin.py +++ b/app/views/admin.py @@ -15,6 +15,7 @@ admin = Admin(app, name="Admin", template_mode="bootstrap4") Initialised Admin Portal """ + class ModelView(ModelView): # skipcq: PYL-E0102 """ Our extended ModelView Class @@ -23,6 +24,7 @@ class ModelView(ModelView): # skipcq: PYL-E0102 https://flask-admin.readthedocs.io/en/latest/introduction/?highlight=ModelView#modelview-configuration-attributes """ + def is_accessible(self): """This function checks if a user should be given access or not""" try: @@ -33,4 +35,4 @@ class ModelView(ModelView): # skipcq: PYL-E0102 return False -admin.add_view(ModelView(User, db.session))
\ No newline at end of file +admin.add_view(ModelView(User, db.session)) |