Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: table title can have null relationships #76

Merged
merged 1 commit into from
Sep 2, 2024

Conversation

alexbostock
Copy link
Contributor

Fix for an error seen parsing a private document:

Block looks like this (some properties omitted)

{
    "BlockType": "TABLE_TITLE",
    "Page": 2,
    "PageClassification": null,
    "Query": null,
    "Relationships": null,
    "RowIndex": null,
    "RowSpan": null,
    "SelectionStatus": null,
    "Text": null,
    "TextType": null
}

Typically, a TABLE_TITLE block's relationships are words, but this title does not contain any text.

This could technically be a breaking change, if anybody relies on Relationships not being null. But I don't think this will be the case anywhere: several other block types have nullable relationships.

@alexbostock alexbostock added the bug Something isn't working label Sep 2, 2024
@alexbostock alexbostock requested a review from EHadoux September 2, 2024 11:20
@alexbostock alexbostock self-assigned this Sep 2, 2024
@EHadoux EHadoux merged commit 40553d0 into master Sep 2, 2024
3 checks passed
@EHadoux EHadoux deleted the fix-table-title-block-relationships-null branch September 2, 2024 11:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants