diff options
| author | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2020-10-28 00:36:19 +0100 |
|---|---|---|
| committer | Fabian Mastenbroek <mail.fabianm@gmail.com> | 2020-10-28 11:38:34 +0100 |
| commit | 7e05dc7a885cf562052461565376e174e6a9c962 (patch) | |
| tree | 025412c87b233b88d715f082be37e964e2090931 /frontend/src/components/modals/custom-components/NewPortfolioModalComponent.js | |
| parent | 5ec42736f3f17e9f5432063b4cc17e6ad9a75713 (diff) | |
Migrate to Reactstrap for Modal implementation
Diffstat (limited to 'frontend/src/components/modals/custom-components/NewPortfolioModalComponent.js')
| -rw-r--r-- | frontend/src/components/modals/custom-components/NewPortfolioModalComponent.js | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/frontend/src/components/modals/custom-components/NewPortfolioModalComponent.js b/frontend/src/components/modals/custom-components/NewPortfolioModalComponent.js index 2d001302..19049931 100644 --- a/frontend/src/components/modals/custom-components/NewPortfolioModalComponent.js +++ b/frontend/src/components/modals/custom-components/NewPortfolioModalComponent.js @@ -19,11 +19,13 @@ class NewPortfolioModalComponent extends React.Component { } reset() { - this.textInput.value = '' - AVAILABLE_METRICS.forEach((metric) => { - this.metricCheckboxes[metric].checked = true - }) - this.repeatsInput.value = 1 + if (this.textInput) { + this.textInput.value = '' + AVAILABLE_METRICS.forEach((metric) => { + this.metricCheckboxes[metric].checked = true + }) + this.repeatsInput.value = 1 + } } onSubmit() { |
