Fix for undefined index error. Whoops.