Title: Reset not completing
Last modified: February 19, 2019

---

# Reset not completing

 *  Resolved [Mike Meinz](https://wordpress.org/support/users/mikemeinz/)
 * (@mikemeinz)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/reset-not-completing/)
 * I finally got some time today to research and solve this issue. Prior to today,
   I had been manually working around the issue.
 * **The Issue**
    When I click on the **Reset** button, it never completes. I added
   some code to log to the debug.log and I found that the third $wpdb->query DROP
   TABLE IF EXISTS call never returned. See [Stack Overflow question](https://stackoverflow.com/questions/54768186/wordpress-wpdb-query-does-not-return)
   for detailed documentation on this issue.
 * **The Solution**
    After some research and experimentation, I found that dropping
   all three tables in one statement solved the issue so I replaced the **wpmc_uninstall()**
   function in **core.php** with the following:
 *     ```
       function wpmc_uninstall () {
       	global $wpdb;
       	$table_name1 = $wpdb->prefix . "mclean_scan";
       	$table_name2 = $wpdb->prefix . "mclean_refs";
       	$table_name3 = $wpdb->prefix . "wpmcleaner";
       	$SQL = "DROP TABLE IF EXISTS $table_name1, $table_name2, $table_name3;";
       	$wpdb->query($SQL);
       }
       ```
   

Viewing 1 replies (of 1 total)

 *  Plugin Author [Jordy Meow](https://wordpress.org/support/users/tigroumeow/)
 * (@tigroumeow)
 * [7 years, 1 month ago](https://wordpress.org/support/topic/reset-not-completing/#post-11265419)
 * Hi Mike,
 * That’s really a weird issue, and nobody knew the answer to it. Maybe a bug with
   a specific version of MySQL? Anyway, excellent catch, I have updated the code
   with yours 🙂 Thanks for finding this, I think it will help others too!

Viewing 1 replies (of 1 total)

The topic ‘Reset not completing’ is closed to new replies.

 * ![](https://ps.w.org/media-cleaner/assets/icon-256x256.png?rev=2791576)
 * [Media Cleaner: Clean your WordPress!](https://wordpress.org/plugins/media-cleaner/)
 * [Support Threads](https://wordpress.org/support/plugin/media-cleaner/)
 * [Active Topics](https://wordpress.org/support/plugin/media-cleaner/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/media-cleaner/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/media-cleaner/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [Jordy Meow](https://wordpress.org/support/users/tigroumeow/)
 * Last activity: [7 years, 1 month ago](https://wordpress.org/support/topic/reset-not-completing/#post-11265419)
 * Status: resolved