]> cat aescling's git repositories - mastodon.git/commitdiff
dont crash with null-ref (#12274)
authorHinaloe <hina@hinaloe.net>
Mon, 4 Nov 2019 11:58:19 +0000 (20:58 +0900)
committerEugen Rochko <eugen@zeonfederated.com>
Mon, 4 Nov 2019 11:58:19 +0000 (12:58 +0100)
app/javascript/mastodon/features/ui/index.js

index 791ff9a2e5ae6efb3c2b1ba1b7a2c2331c2ea740..a45ba91eb2663853d3ce3113f9e0600a6abf5014 100644 (file)
@@ -164,7 +164,9 @@ class SwitchingColumnsArea extends React.PureComponent {
   }
 
   setRef = c => {
-    this.node = c.getWrappedInstance();
+    if (c) {
+      this.node = c.getWrappedInstance();
+    }
   }
 
   render () {