From be167d83102ae5a6f4e51f22a3c4cc306820804c Mon Sep 17 00:00:00 2001 From: "Valentin D. Pinkman" Date: Tue, 5 Feb 2019 16:25:48 +0100 Subject: [PATCH] clear on success and error --- src/components/SettingsPage/RepairDeviceButton.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/components/SettingsPage/RepairDeviceButton.js b/src/components/SettingsPage/RepairDeviceButton.js index b36e6254..b3dc3457 100644 --- a/src/components/SettingsPage/RepairDeviceButton.js +++ b/src/components/SettingsPage/RepairDeviceButton.js @@ -58,9 +58,11 @@ class RepairDeviceButton extends PureComponent { }, error: error => { logger.critical(error) + if (this.timeout) clearTimeout(this.timeout) this.setState({ error, isLoading: false, progress: 0 }) }, complete: () => { + if (this.timeout) clearTimeout(this.timeout) this.setState({ opened: false, isLoading: false, progress: 0 }, () => { push('/manager') })