closer to working find function