Skip to content

Commit f748b6c

Browse files
committed
Add explicit str check on dts path
1 parent 2d0588f commit f748b6c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

keymap_drawer/physical_layout.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -636,6 +636,8 @@ def _parse_dts_layout(dts_in: Path | BytesIO | bytes, cfg: ParseConfig) -> QmkLa
636636
in_str, file_name = f.read(), str(dts_in)
637637
elif isinstance(dts_in, BytesIO):
638638
in_str, file_name = dts_in.read().decode("utf-8"), None
639+
elif isinstance(dts_in, str):
640+
in_str, file_name = dts_in, None
639641
else: # bytes
640642
in_str, file_name = dts_in.decode("utf-8"), None
641643

0 commit comments

Comments
 (0)