Skip to content

Commit

Permalink
Minor fix for daemon commands
Browse files Browse the repository at this point in the history
  • Loading branch information
alexcarrega committed Feb 8, 2022
1 parent 62bd401 commit c1596b4
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion scripts/start.sh
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#!/bin/sh
#!/bin/bash

# Copyright (c) 2020-2029 GUARD Project (https://www.guard-project.eu)
# author: Alex Carrega <alessandro.carrega@cnit.it>
Expand Down
7 changes: 5 additions & 2 deletions src/libs/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,11 @@ def add(cls: Type[T], id: str, data: Dict[T.ActionModel]) -> None:

@staticmethod
def process(data: str) -> List[str]:
__process = map(lambda item: item.strip(), data.split("\n"))
return list(filter(lambda item: item, __process))
try:
__process = map(lambda item: item.strip(), data.split("\n"))
return list(filter(lambda item: item, __process))
except Exception:
return []

@classmethod
def action(
Expand Down

0 comments on commit c1596b4

Please sign in to comment.