mirror of
https://github.com/ha7ilm/openwebrx.git
synced 2026-04-04 22:17:34 +00:00
refactor authentication / authorization into a mixin
This commit is contained in:
parent
8422a33081
commit
17c20d12e0
3 changed files with 9 additions and 8 deletions
|
|
@ -1,4 +1,3 @@
|
|||
from .template import WebpageController
|
||||
from .session import SessionStorage
|
||||
from owrx.config import Config
|
||||
from owrx.users import UserList
|
||||
|
|
@ -25,7 +24,7 @@ class Authentication(object):
|
|||
return None
|
||||
|
||||
|
||||
class AdminController(WebpageController):
|
||||
class AuthorizationMixin(object):
|
||||
def __init__(self, handler, request, options):
|
||||
self.authentication = Authentication()
|
||||
self.user = self.authentication.getUser(request)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue