mirror of
https://github.com/BoardWare-Genius/jarvis-models.git
synced 2025-12-14 17:13:25 +00:00
refactor: args
This commit is contained in:
@ -7,10 +7,12 @@ from .blackbox import Blackbox
|
||||
|
||||
class SUM(Blackbox):
|
||||
|
||||
def valid(self, data: any) -> bool:
|
||||
def valid(self, *args, **kwargs) -> bool:
|
||||
data = args[0]
|
||||
return isinstance(data, list)
|
||||
|
||||
def processing(self, data: list) -> Coroutine[Any, Any, Any]:
|
||||
def processing(self, *args, **kwargs) -> Coroutine[Any, Any, Any]:
|
||||
data = args[0]
|
||||
return sum(data)
|
||||
|
||||
async def fast_api_handler(self, request: Request) -> Response:
|
||||
|
||||
Reference in New Issue
Block a user