persist method

Future<void> persist()

Implementation

Future<void> persist() async {
  if (isEmpty) {
    logger.log('Persist canceled. Empty store');
    return;
  }

  if (!isDirty) {
    logger.log('Persist canceled. Clean store.');
    return;
  }

  _logSize();

  await logger.measure('Persist', () => config.persist(_store));
  isDirty = false;
}