Skip to content
This repository has been archived by the owner on Feb 16, 2020. It is now read-only.

Commit

Permalink
only render warmup warning when there is required history
Browse files Browse the repository at this point in the history
  • Loading branch information
askmike committed Jul 25, 2018
1 parent 6b195e5 commit 211b0b8
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion web/vue/src/components/gekko/singleGekko.vue
Original file line number Diff line number Diff line change
Expand Up @@ -195,7 +195,13 @@ export default {
return false;
}
const warmupTime = _.get(this.config, 'tradingAdvisor.candleSize') * _.get(this.config, 'tradingAdvisor.historySize');
const historySize = _.get(this.config, 'tradingAdvisor.historySize');
if(!historySize) {
return false;
}
const warmupTime = _.get(this.config, 'tradingAdvisor.candleSize') * historySize;
return humanizeDuration(
moment(this.initialEvents.candle.start).add(warmupTime, 'm').diff(moment()),
Expand Down

0 comments on commit 211b0b8

Please sign in to comment.