dist/js/idbhelper.js
/**
   * Delete idb restaurants index if exists
   */
Delete idb restaurants index if exists
Delete idb restaurants index if exists
static deleteOldDatabase() {
    let DBDeleteRequest = window.indexedDB.deleteDatabase("restaurants-db");
    DBDeleteRequest.onerror = function () {
      console.log("Error deleting database.");
    };
    DBDeleteRequest.onsuccess = function () {
      console.log("Old db successfully deleted!");
    };
  }
static deleteOldDatabase ( ) { let DBDeleteRequest = window . indexedDB . deleteDatabase ( "restaurants-db" ) ; DBDeleteRequest . onerror = function ( ) { console . log ( "Error deleting database." ) ; } ; DBDeleteRequest . onsuccess = function ( ) { console . log ( "Old db successfully deleted!" ) ; } ; }
Delete idb restaurants index if exists
Delete idb restaurants index if exists