refactor: Rename load_local_blocklist -> load_blocklist_file

This commit is contained in:
moanos [he/him] 2023-01-12 16:01:55 +01:00 committed by Georg Krause
parent 0ecc925373
commit 0dd6930c0f
No known key found for this signature in database
GPG Key ID: 2970D504B2183D22

View File

@ -9,7 +9,7 @@ import toml
from mastodon_blocklist_deploy.models import Instance
def load_local_blocklist(filename: str) -> [Instance]:
def load_blocklist_file(filename: str) -> [Instance]:
with open(filename, "r") as f:
data = toml.load(f)
instances = []
@ -89,7 +89,7 @@ def cli():
blocklist_filename = args.input_file
else:
blocklist_filename = "../blocklist.toml"
local_blocklist = load_local_blocklist(blocklist_filename)
local_blocklist = load_blocklist_file(blocklist_filename)
if args.action == "diff":
Instance.show_diffs(local_blocklist, remote_blocklist)