Changed the array returned to an associative array so we can match with the thumbnails in the js