mirror of
https://github.com/itdoginfo/allow-domains.git
synced 2026-03-26 06:46:24 +03:00
Fix: fix from copilot
This commit is contained in:
@@ -96,6 +96,7 @@ def mikrotik_fwd(src, out, remove={'google.com'}):
|
||||
|
||||
def lines_from_file(filepath):
|
||||
if not os.path.exists(filepath):
|
||||
print(f"Warning: input file not found: {filepath}", file=sys.stderr)
|
||||
return []
|
||||
with open(filepath, 'r', encoding='utf-8') as f:
|
||||
return [line.strip() for line in f if line.strip()]
|
||||
|
||||
Reference in New Issue
Block a user