Fixed undefined index notices