From 16e4dd4316b4ef6efb7544f5191fd650a5c1077b Mon Sep 17 00:00:00 2001 From: Jeremy Press Date: Fri, 1 Dec 2017 14:23:53 -0800 Subject: [PATCH] Fix: Properly bind download button in PreviewErrorViewer --- src/lib/viewers/error/PreviewErrorViewer.js | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/src/lib/viewers/error/PreviewErrorViewer.js b/src/lib/viewers/error/PreviewErrorViewer.js index e5ab737fc..7db968e08 100644 --- a/src/lib/viewers/error/PreviewErrorViewer.js +++ b/src/lib/viewers/error/PreviewErrorViewer.js @@ -7,11 +7,15 @@ import './PreviewError.scss'; class PreviewErrorViewer extends BaseViewer { /** - * [constructor] - * - * @param {string|HTMLElement} container - The container - * @param {Object} options - Some options - * @return {Error} Error instance + * @inheritdoc + */ + constructor(options) { + super(options); + this.download = this.download.bind(this); + } + + /** + * @inheritdoc */ setup() { // Call super() first to set up common layout