diff --git a/owrx/controllers/__init__.py b/owrx/controllers/__init__.py index 99bfad2..6e0be48 100644 --- a/owrx/controllers/__init__.py +++ b/owrx/controllers/__init__.py @@ -1,8 +1,7 @@ -from abc import ABC, abstractmethod from datetime import datetime -class Controller(ABC): +class Controller(object): def __init__(self, handler, request, options): self.handler = handler self.request = request diff --git a/owrx/controllers/template.py b/owrx/controllers/template.py index 3938719..6746012 100644 --- a/owrx/controllers/template.py +++ b/owrx/controllers/template.py @@ -1,10 +1,9 @@ from . import Controller import pkg_resources from string import Template -from abc import ABCMeta -class TemplateController(Controller, metaclass=ABCMeta): +class TemplateController(Controller): def render_template(self, file, **vars): file_content = pkg_resources.resource_string("htdocs", file).decode("utf-8") template = Template(file_content) @@ -18,7 +17,7 @@ class TemplateController(Controller, metaclass=ABCMeta): return {} -class WebpageController(TemplateController, metaclass=ABCMeta): +class WebpageController(TemplateController): def template_variables(self): header = self.render_template("include/header.include.html") return {"header": header}