Skip to content

Commit

Permalink
Make all configurations optional
Browse files Browse the repository at this point in the history
  • Loading branch information
thevahidal committed Jan 11, 2025
1 parent 16f7acf commit 81ac7bc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions script.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ def load_data(file_path):
raw_data = tomllib.load(f)

return Data(
name=raw_data["name"],
name=raw_data.get("name", ""),
description=raw_data.get("description"),
keywords=raw_data.get("keywords"),
base_url=raw_data["base_url"],
base_url=raw_data.get("base_url", ""),
image=raw_data.get("image"),
theme=raw_data.get("theme", "dark"),
primary_color=raw_data.get("primary_color", "#546e7a"),
Expand Down

0 comments on commit 81ac7bc

Please sign in to comment.