From ad9e125e24c3b5604480cc4fdf5c5bb9319e6ab9 Mon Sep 17 00:00:00 2001 From: ajaezokingsley Date: Fri, 22 Oct 2021 14:30:54 -0700 Subject: [PATCH] refactor of if else to tenary for simplicity --- src/App.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/App.js b/src/App.js index c3284bde..8e248937 100644 --- a/src/App.js +++ b/src/App.js @@ -5,14 +5,13 @@ import './index.css'; function Router() { const { streamData } = useMovie(); - if (streamData) return ; - else return ; + return streamData ? : ; } function App() { return ( - + ); }