Changed fail array to assocative array