0

I keep getting the following error for some reason:

Fatal error: Cannot redeclare media_views_invalidate_cache() (previously declared in /var/www/html/sitename/sites/all/modules/media/media.views.inc:140) in /var/www/html/sitename/profiles/dkan/modules/contrib/media/media.views.inc on line 140

Is there any reason I'm getting the error?

I'm using Drupal 7.54.

1

Looks like you have media installed twice. Once as part of your installation profile (or distribution) and once as a 'loose' module. Which I suppose occurred because there was a security update and you did not want to wait for the distribution to update.

Make a backup and remove /sites/all/modules/media. That should solve it.

  • Well I did that, however, it shows the following error message: User warning: The following module has moved within the file system: media. In order to fix this, clear caches or put the module back in its original location. For more information, see the documentation page. in _drupal_trigger_error_with_delayed_logging() (line 1138 of /var/www/html/sitename/includes/bootstrap.inc). I also did a drush rr and it crashed the system and just a regular clean cache and it also crashes the system. – Kevin Davis Jun 9 '17 at 14:23
  • And what if you disable or uninstall it first? You'll need to get rid of the 2nd installation somehow – Neograph734 Jun 9 '17 at 17:46

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.