From d06b71589b6e86ab0e59a781052bf241976e8669 Mon Sep 17 00:00:00 2001 From: "a.soldatof" Date: Sun, 19 May 2019 11:06:00 +0300 Subject: [PATCH] fix error --- src/Game.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/Game.js b/src/Game.js index 6b91ceb..e83f054 100644 --- a/src/Game.js +++ b/src/Game.js @@ -85,7 +85,9 @@ export class Game extends Component { } componentDidUpdate() { - this.tipsListRef.current.scrollTop = 10000; + if(this.tipsListRef && this.tipsListRef.current) { + this.tipsListRef.current.scrollTop = 10000; + } } askTip = () => { -- 2.50.1