hotfix: glaring mistake while parsing text runs
This commit is contained in:
@@ -471,7 +471,7 @@ def extractTextFromSimpleOrRuns(obj: dict, default: str = "") -> str:
|
|||||||
# Extracts the text both from "runs" and "simpleText"
|
# Extracts the text both from "runs" and "simpleText"
|
||||||
# with failsafe to default.
|
# with failsafe to default.
|
||||||
text = default
|
text = default
|
||||||
if not isinstance(obj, str):
|
if not isinstance(obj, dict):
|
||||||
return default
|
return default
|
||||||
if "runs" in obj:
|
if "runs" in obj:
|
||||||
text = runsToText(obj["runs"])
|
text = runsToText(obj["runs"])
|
||||||
|
|||||||
Reference in New Issue
Block a user