mirror of
https://github.com/YunoHost-Apps/ihatemoney_ynh.git
synced 2024-09-03 19:26:15 +02:00
remove unused code
If that code is ever needed, I'll try to rewrite it as a class decorator, which is more hype
This commit is contained in:
parent
353aec4f1e
commit
46d2dfeb29
1 changed files with 0 additions and 9 deletions
|
@ -32,12 +32,3 @@ class Redirect303(HTTPException, RoutingException):
|
||||||
|
|
||||||
def get_response(self, environ):
|
def get_response(self, environ):
|
||||||
return redirect(self.new_url, 303)
|
return redirect(self.new_url, 303)
|
||||||
|
|
||||||
|
|
||||||
def for_all_methods(decorator):
|
|
||||||
"""Apply a decorator to all the methods of a class"""
|
|
||||||
def decorate(cls):
|
|
||||||
for name, method in inspect.getmembers(cls, inspect.ismethod):
|
|
||||||
setattr(cls, name, decorator(method))
|
|
||||||
return cls
|
|
||||||
return decorate
|
|
||||||
|
|
Loading…
Reference in a new issue