Fix regression on startup when ES isn't running

Issue #538