Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions graphrag/config/environment_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,10 @@

def read_key(value: KeyValue) -> str:
"""Read a key value."""
if not isinstance(value, str):
return value.value.lower()
return value.lower()
# Use type(value) is str for faster type checking than isinstance
if type(value) is str:
return value.lower()
return value.value.lower()


class EnvironmentReader:
Expand Down