search works now on front end. doesnt use promises yet, but thats in the works