fix for undefined notifications object causing a 500