fix bug in findwhere