Skip to content

Commit

Permalink
Fix issue with typings for ConstraintDataStore.serialize
Browse files Browse the repository at this point in the history
  • Loading branch information
shueja committed Sep 3, 2024
1 parent 6c15997 commit 81b5e7d
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class PointAtOverlay extends Component<Props<"PointAt">, object> {
if (this.props.start === undefined) {
return <></>;
}
const data = this.props.data.serialize() as DataMap["PointAt"];
const data = this.props.data.serialize as DataMap["PointAt"];
return (
<g ref={this.rootRef}>
<circle
Expand Down
2 changes: 1 addition & 1 deletion src/document/ConstraintDataStore.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ export type ConstraintDataStore<
> = IModelType<
DataStoreProps<K>,
ConstraintSetters<K> & {
serialize: () => D;
serialize: D;
deserialize: (ser: D) => void;
deserPartial: (ser: Partial<D["props"]>) => void;
}
Expand Down
2 changes: 1 addition & 1 deletion src/document/path/ChoreoPathStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,7 +100,7 @@ export const ChoreoPathStore = types
const from = self.waypointIdToSavedWaypointId(con.from)!;
const to = self.waypointIdToSavedWaypointId(con.to);
const toReturn: Constraint = {
data: con.data.serialize(),
data: con.data.serialize,
from,
to
};
Expand Down

0 comments on commit 81b5e7d

Please sign in to comment.