Execute oncreate scrubber update after loadPromise has completed

This way, we ensure that the initial position (and data) of the scrubber is correct. Otherwise, we get blank dates / incorrect location.
This commit is contained in:
Alexander Skvortsov 2020-09-20 00:52:28 -04:00
parent a17f1247a8
commit 8640ce83b5

View File

@ -137,7 +137,7 @@ export default class PostStreamScrubber extends Component {
setTimeout(() => this.scrollListener.start());
this.updateScrubberValues({ animate: true, forceHeightChange: true });
this.stream.loadPromise.then(() => this.updateScrubberValues({ animate: true, forceHeightChange: true }));
}
onremove() {