diff --git a/ythdd_struct_parser.py b/ythdd_struct_parser.py index 8f56fca..efe1377 100644 --- a/ythdd_struct_parser.py +++ b/ythdd_struct_parser.py @@ -471,7 +471,7 @@ def extractTextFromSimpleOrRuns(obj: dict, default: str = "") -> str: # Extracts the text both from "runs" and "simpleText" # with failsafe to default. text = default - if not isinstance(obj, str): + if not isinstance(obj, dict): return default if "runs" in obj: text = runsToText(obj["runs"])