Code Duplication    Length = 16-16 lines in 2 locations

core/db_models/EEM_Base.model.php 2 locations

@@ 2323-2338 (lines=16) @@
2320
     * @param array  $arguments_to_provide
2321
     * @return string
2322
     */
2323
    private function _verify_core_db($wpdb_method, $arguments_to_provide)
2324
    {
2325
        /** @type WPDB $wpdb */
2326
        global $wpdb;
2327
        //ok remember that we've already attempted fixing the core db, in case the problem persists
2328
        EEM_Base::$_db_verification_level = EEM_Base::db_verified_core;
2329
        $error_message = sprintf(
2330
            __('WPDB Error "%1$s" while running wpdb method "%2$s" with arguments %3$s. Automatically attempting to fix EE Core DB',
2331
                'event_espresso'),
2332
            $wpdb->last_error,
2333
            $wpdb_method,
2334
            wp_json_encode($arguments_to_provide)
2335
        );
2336
        EE_System::instance()->initialize_db_if_no_migrations_required(false, true);
2337
        return $error_message;
2338
    }
2339
2340
2341
@@ 2350-2365 (lines=16) @@
2347
     * @param $arguments_to_provide
2348
     * @return string
2349
     */
2350
    private function _verify_addons_db($wpdb_method, $arguments_to_provide)
2351
    {
2352
        /** @type WPDB $wpdb */
2353
        global $wpdb;
2354
        //ok remember that we've already attempted fixing the addons dbs, in case the problem persists
2355
        EEM_Base::$_db_verification_level = EEM_Base::db_verified_addons;
2356
        $error_message = sprintf(
2357
            __('WPDB AGAIN: Error "%1$s" while running the same method and arguments as before. Automatically attempting to fix EE Addons DB',
2358
                'event_espresso'),
2359
            $wpdb->last_error,
2360
            $wpdb_method,
2361
            wp_json_encode($arguments_to_provide)
2362
        );
2363
        EE_System::instance()->initialize_addons();
2364
        return $error_message;
2365
    }
2366
2367
2368