Fixed undefined index warnings
Merge remote-tracking branch 'origin/master'