Restructurated backend

This commit is contained in:
DomySh
2022-07-21 01:02:46 +02:00
parent d4cc2f566c
commit 0ed8bb635e
15 changed files with 523 additions and 409 deletions

View File

@@ -1,5 +1,5 @@
from typing import Dict, List, Set
from utils import ip_parse, ip_family
from utils import ip_parse, ip_family, run_func
from modules.sqlite import Service
import re, os, asyncio
import traceback, nftables
@@ -182,8 +182,7 @@ class RegexFilter:
async def update(self):
if self.update_func:
if asyncio.iscoroutinefunction(self.update_func): await self.update_func(self)
else: self.update_func(self)
await run_func(self.update_func, self)
class FiregexInterceptor: