Skip to content

Commit

Permalink
Merge pull request #422 from SEDAdigital/refresh_namespaces
Browse files Browse the repository at this point in the history
Force rebuilding namespaces after building namespaces on Revo 3
  • Loading branch information
muzzwood authored Mar 16, 2023
2 parents 1aea304 + 4dbe3d2 commit cea9319
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/Command/BuildCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -434,6 +434,14 @@ public function buildObjects($folder, $type)
$this->removeOrphans($type);

$this->resolveConflicts($folder, $type);

if (
class_exists('\modX\Revolution\modNamespace') &&
in_array($type['class'], ['modNamespace', '\modNamespace', '\modX\Revolution\modNamespace'], true)
) {
$this->modx->getCacheManager()-> generateNamespacesCache('namespaces');
\modX\Revolution\modNamespace::loadCache($this->modx);
}
}

/**
Expand Down

0 comments on commit cea9319

Please sign in to comment.