Fixed find() function