Only send to elasticsearch if enabled