ensureDBIsInitialized method

Future<void> ensureDBIsInitialized()

Ensures the database is initialized and ready for use.

This method checks if the database has been initialized. If not, it calls the init method to initialize the database.

Implementation

Future<void> ensureDBIsInitialized() async {
  if (!dbIsReady) {
    await init();
  }
}