diff options
author | bob <bcz@cs.brown.edu> | 2020-01-31 12:40:03 -0500 |
---|---|---|
committer | bob <bcz@cs.brown.edu> | 2020-01-31 12:40:03 -0500 |
commit | e34620f6ded8afd6bb3f96c2c2889c9165f64569 (patch) | |
tree | 96062720ffc04699b0d489e7c11e15da4761113c /src | |
parent | 0c9c2b9fef0b735e4d8398e2a137feb5a6db203a (diff) | |
parent | 5ad15ac012262ac15e152b995cbcb042c5b7cf89 (diff) |
Merge branch 'master' of https://github.com/browngraphicslab/Dash-Web
Diffstat (limited to 'src')
-rw-r--r-- | src/client/views/collections/CollectionTreeView.tsx | 2 | ||||
-rw-r--r-- | src/client/views/nodes/ImageBox.tsx | 1 | ||||
-rw-r--r-- | src/server/updateSearch.ts | 12 |
3 files changed, 10 insertions, 5 deletions
diff --git a/src/client/views/collections/CollectionTreeView.tsx b/src/client/views/collections/CollectionTreeView.tsx index 6cc2d6586..3cb24f079 100644 --- a/src/client/views/collections/CollectionTreeView.tsx +++ b/src/client/views/collections/CollectionTreeView.tsx @@ -634,7 +634,7 @@ export class CollectionTreeView extends CollectionSubView(Document) { DocListCast(d.data).map((img, i) => { const caption = (d.captions as any)[i]?.data; if (caption instanceof ObjectField) { - Doc.GetProto(img).caption = ObjectField.MakeCopy(caption as ObjectField); + Doc.GetProto(img).caption = ObjectField.MakeCopy(caption); } d.captions = undefined; }); diff --git a/src/client/views/nodes/ImageBox.tsx b/src/client/views/nodes/ImageBox.tsx index 33c694c6e..382ca526d 100644 --- a/src/client/views/nodes/ImageBox.tsx +++ b/src/client/views/nodes/ImageBox.tsx @@ -67,6 +67,7 @@ const uploadIcons = { @observer export class ImageBox extends DocAnnotatableComponent<FieldViewProps, ImageDocument>(ImageDocument) { + protected multiTouchDisposer?: import("../../util/InteractionUtils").InteractionUtils.MultiTouchEventDisposer | undefined; public static LayoutString(fieldKey: string) { return FieldView.LayoutString(ImageBox, fieldKey); } private _imgRef: React.RefObject<HTMLImageElement> = React.createRef(); private _dropDisposer?: DragManager.DragDropDisposer; diff --git a/src/server/updateSearch.ts b/src/server/updateSearch.ts index 83094d36a..dd2067c87 100644 --- a/src/server/updateSearch.ts +++ b/src/server/updateSearch.ts @@ -107,11 +107,15 @@ async function update() { color: cyan }); try { - const { status } = JSON.parse(result).responseHeader; - console.log(status ? red(`Failed with status code (${status})`) : green("Success!")); - } catch { + if (result) { + const { status } = JSON.parse(result).responseHeader; + console.log(status ? red(`Failed with status code (${status})`) : green("Success!")); + } else { + console.log(red("Solr is likely not running!")); + } + } catch (e) { console.log(red("Error:")); - console.log(result); + console.log(e); console.log("\n"); } await cursor?.close(); |