better code, elastic search works