refactor: clean up catch block formatting and comment out version display in Sidebar
This commit is contained in:
@@ -104,14 +104,14 @@ export default function Sidebar() {
|
|||||||
try {
|
try {
|
||||||
const parsed = JSON.parse(adminNotifs);
|
const parsed = JSON.parse(adminNotifs);
|
||||||
setAdminUnreadCount(parsed.filter((n: any) => !n.read).length);
|
setAdminUnreadCount(parsed.filter((n: any) => !n.read).length);
|
||||||
} catch (e) {}
|
} catch (e) { }
|
||||||
}
|
}
|
||||||
const invNotifs = localStorage.getItem('jaiben_investor_notifications');
|
const invNotifs = localStorage.getItem('jaiben_investor_notifications');
|
||||||
if (invNotifs) {
|
if (invNotifs) {
|
||||||
try {
|
try {
|
||||||
const parsed = JSON.parse(invNotifs);
|
const parsed = JSON.parse(invNotifs);
|
||||||
setInvestorUnreadCount(parsed.filter((n: any) => !n.read).length);
|
setInvestorUnreadCount(parsed.filter((n: any) => !n.read).length);
|
||||||
} catch (e) {}
|
} catch (e) { }
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -190,7 +190,7 @@ export default function Sidebar() {
|
|||||||
const isActive = isExact || isChild;
|
const isActive = isExact || isChild;
|
||||||
const Icon = item.icon;
|
const Icon = item.icon;
|
||||||
const isNotification = item.label === 'Notifications';
|
const isNotification = item.label === 'Notifications';
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Link
|
<Link
|
||||||
key={item.href}
|
key={item.href}
|
||||||
@@ -235,10 +235,10 @@ export default function Sidebar() {
|
|||||||
<LogOut className="w-4 h-4 text-slate-400" />
|
<LogOut className="w-4 h-4 text-slate-400" />
|
||||||
</button>
|
</button>
|
||||||
</Link>
|
</Link>
|
||||||
<div className="mt-2 text-xs text-slate-400 text-center">
|
{/* <div className="mt-2 text-xs text-slate-400 text-center">
|
||||||
<p>Phase 1 - Core EV Rental</p>
|
<p>Phase 1 - Core EV Rental</p>
|
||||||
<p className="mt-1">v1.0.0</p>
|
<p className="mt-1">v1.0.0</p>
|
||||||
</div>
|
</div> */}
|
||||||
</div>
|
</div>
|
||||||
</aside>
|
</aside>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user