Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix bug with missing UniqueID.number field in PageProperty.
I ran into a bug today where my notion-client was failing to deserialize a Page containing a PageProperty.UniqueID.unique_id field whose UniqueIDPropertyValue.number field was null. 99.999% of the time UniqueIDPropertyValue.number is non-null, but it can be null for instance in the case where you use one of Notion's templates to create a Task Page with a null UniqueIDPropertyValue.number field, but that's OK because the Task Page will always be copied to make a new Task and the unique ID field will be filled in with some value. This change to make number an Option<Number> instead of just Number reflects the fact that it could be null, though it is very unlikely.
- Loading branch information