Fixed elasticsearch repository