Fixing some broken code in the sidebar