diff options
author | Bob Zeleznik <zzzman@gmail.com> | 2020-07-22 11:33:28 -0400 |
---|---|---|
committer | Bob Zeleznik <zzzman@gmail.com> | 2020-07-22 11:33:28 -0400 |
commit | 828a28e112db3357f52d3923987070129fd64b21 (patch) | |
tree | b80f55788a8ee31e95fccc12c6f95bfb0d8c7f39 /src/client/views/PreviewCursor.tsx | |
parent | 9d530f8fc7ca9621274a38260faebe797f66dd60 (diff) |
restored download document. fixed clone() to clone to be async and handles lists properly.
Diffstat (limited to 'src/client/views/PreviewCursor.tsx')
-rw-r--r-- | src/client/views/PreviewCursor.tsx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/client/views/PreviewCursor.tsx b/src/client/views/PreviewCursor.tsx index 6583589f3..2d51403d7 100644 --- a/src/client/views/PreviewCursor.tsx +++ b/src/client/views/PreviewCursor.tsx @@ -69,11 +69,11 @@ export class PreviewCursor extends React.Component<{}> { const list: Doc[] = []; let first: Doc | undefined; - docids.map((did, i) => i && DocServer.GetRefField(did).then(doc => { + docids.map((did, i) => i && DocServer.GetRefField(did).then(async doc => { count++; if (doc instanceof Doc) { i === 1 && (first = doc); - const alias = clone ? Doc.MakeClone(doc) : doc; + const alias = clone ? await Doc.MakeClone(doc) : doc; const deltaX = NumCast(doc.x) - NumCast(first!.x) - ptx; const deltaY = NumCast(doc.y) - NumCast(first!.y) - pty; alias.x = newPoint[0] + deltaX; |