Fix #646 deleteby query should not throw if no default index is set