After i want uninstall module get bellow error

Recoverable fatal error: Argument 1 passed to file_delete() must be an instance of stdClass, boolean given, called in /var/www/site/sites/all/modules/nivo_slider/nivo_slider.install on line 23 and defined in file_delete() (line 1272 of /var/www/bestnik/includes/file.inc). Backtrace:

file_delete() nivo_slider.install:23
nivo_slider_uninstall() 
call_user_func_array('nivo_slider_uninstall', Array) module.inc:922
module_invoke('nivo_slider', 'uninstall') install.inc:809
drupal_uninstall_modules(Array) system.admin.inc:1376
system_modules_uninstall_submit(Array, Array) form.inc:1519
form_execute_handlers('submit', Array, Array) form.inc:903
drupal_process_form('system_modules_uninstall', Array, Array) form.inc:385
drupal_build_form('system_modules_uninstall', Array) form.inc:130
drupal_get_form('system_modules_uninstall') 
call_user_func_array('drupal_get_form', Array) menu.inc:527
menu_execute_active_handler() index.php:21

Comments

rfnbnkr created an issue. See original summary.

Adrião Neves’s picture

That piece of code tries to remove all slide images before uninstalling the module, if you don't want to mess with the code, just manually remove all slide images before and then you will be able to uninstall the module. I know this is not the best solution, but if you in a hurry to remove the module this may help.

caspervoogt’s picture

For anyone else dealing with this; before disabling Nivo Slider, go to the admin page for Nivo Slider (/admin/structure/nivo-slider) and delete all the images on that page. Then disable and uninstall the module.

andrey.troeglazov’s picture

Assigned: Unassigned » andrey.troeglazov
andrey.troeglazov’s picture

Issue tags: +Nivo slider 7.x-1.12

  • andrey.troeglazov authored 02eb325 on 7.x-1.x
    Issue #2685431 by arefen, andrey.troeglazov, Adrião Neves, caspervoogt:...
andrey.troeglazov’s picture

Assigned: andrey.troeglazov » Unassigned
Status: Active » Fixed

Seems I have fixed the problem in dev version. Adding to new release. For me it works ok, if you have any troubles please reopen the ticket.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.