Only display usage on lcars when in use

This commit is contained in:
Tanner Collin 2023-01-18 05:38:48 +00:00
parent e574d71fdb
commit fc62da9c5c

View File

@ -69,7 +69,8 @@ export function DisplayUsage(props) {
return () => clearInterval(interval); return () => clearInterval(interval);
}, []); }, []);
const showUsage = usage && usage.track.username === usage.username; const inUse = usage && moment().unix() - usage.track.time <= 60;
const showUsage = usage && inUse && usage.track.username === usage.username;
return ( return (
<> <>