I'm upgrading my custom media modules to use the "core media" in Drupal 8.4.8

I have to run the command "drush [sitename] updb" twice in order to recognise my custom media modules code has been upgraded.

The first run - it show me an error, I need to upgrade my custom media modules to be compatible with the core media. However, if I run the same command again, it then show me a list of the updates is going to run.

My question, Why I have to run it twice to get it recognise my custom media modules has been updated. This will also caused a problem during deployment, because the deployment only run this command once.

  • 1
    Can one trigger database updates from hook_update_N itself? – leymannx Apr 8 at 6:10
  • I'll try that @leymannx – fkaufusi Apr 9 at 1:31

Your Answer

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

Browse other questions tagged or ask your own question.