added recursive search option