code hardening for dashboard