deleteAll static method

Future<Exception?> deleteAll(
  1. String table
)

Implementation

static Future<Exception?> deleteAll(String table) async {

  if (!initialized) return null;

  Exception? exception;
  try {
    var box = await Hive.openBox(table);
    await box.clear();
  } on Exception catch (e) {
    Log().error('Error Clearing Table [$table]');
    Log().exception(e,
        caller: 'Future<Exception?> deleteAll(String $table) async');
    exception = e;
  }
  return exception;
}