JFIFxxC      C  " }!1AQa"q2#BR$3br %&'()*456789:CDEFGHIJSTUVWXYZcdefghijstuvwxyz w!1AQaq"2B #3Rbrlang); if (\Auth::user()->type == 'super admin') { if (Schema::hasTable('ch_messages')) { if (Schema::hasColumn('ch_messages', 'type') == false) { Schema::drop('ch_messages'); \DB::table('migrations')->where('migration', 'like', '%ch_messages%')->delete(); } } // $migrations = $this->getMigrations(); // $dbMigrations = $this->getExecutedMigrations(); // // $numberOfUpdatesPending = (count($migrations) + 6) - count($dbMigrations); // $numberOfUpdatesPending = (count($migrations)) - count($dbMigrations); $migrations = $this->getMigrations(); $messengerMigration = Utility::get_messenger_packages_migration(); $dbMigrations = $this->getExecutedMigrations(); $Modulemigrations = glob(base_path() . '/Modules/LandingPage/Database' . DIRECTORY_SEPARATOR . 'Migrations' . DIRECTORY_SEPARATOR . '*.php'); $numberOfUpdatesPending = (count($migrations) + count($Modulemigrations) + $messengerMigration) - count($dbMigrations); if ($numberOfUpdatesPending > 0) { // run code like seeder only when new migration Utility::addNewData(); return redirect()->route('LaravelUpdater::welcome'); } } } return $next($request); } }