Skip to content
This repository was archived by the owner on Sep 22, 2021. It is now read-only.
This repository was archived by the owner on Sep 22, 2021. It is now read-only.

Make _updateCollectionData null-safe #4

@sionzee

Description

@sionzee

When you scope your data eg.
let $scope = model.scope('_page.variable') And set it to null
$scope.set(null);
In method react-sharedb/lib/subscribe.js: _updateCollectionData, will be called:
this.data = (0, _observerUtil.observable)(this.data);
Where this.data == null;
In observer methods it will test if it is not instrument and call on it:
var constructor = ref.constructor Where ref will be null.

Temporary fix for this is to set false insteadof null.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions