small fixes for elasticsearch