function _panopoly_core_rollback_demo_content in Panopoly Core 7
Helpfer function to import demo content for apps using Migrate.
File
- ./
panopoly_core.module, line 321
Code
function _panopoly_core_rollback_demo_content($classes = array()) {
// Roll back the migrations to delete the demo content.
foreach ($classes as $class) {
// Get a handle on our migration class.
$migration = Migration::getInstance($class);
// Disable message output from migrate ince this import is used within
// the context of the Apps module where these messages make no sense.
Migration::setDisplayFunction('_panopoly_core_null_message');
// Roll back the migration.
$migration
->processRollback();
// deregister the Migration classes since it will not exist after the
// module is disabled.
Migration::deregisterMigration($class);
}
}