Skip to content

Commit

Permalink
Update restorablepool.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
vidartf committed Dec 14, 2019
1 parent e451082 commit 4a77e12
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/coreutils/src/restorablepool.ts
Expand Up @@ -138,7 +138,7 @@ export class RestorablePool<

if (objName) {
const name = `${this.namespace}:${objName}`;
const data = this._restore.args(obj);
const data = this._restore.args?.(obj);

Private.nameProperty.set(obj, name);
await connector.save(name, { data });
Expand Down Expand Up @@ -298,7 +298,7 @@ export class RestorablePool<
Private.nameProperty.set(obj, newName);

if (newName) {
const data = this._restore.args(obj);
const data = this._restore.args?.(obj);
await connector.save(newName, { data });
}

Expand Down

0 comments on commit 4a77e12

Please sign in to comment.