Shopware\Plugin\Services\Install::checkForNewStructure PHP Method

checkForNewStructure() private method

private checkForNewStructure ( Shopware\Plugin\Struct\Plugin $plugin, string $shopwarePath )
$plugin Shopware\Plugin\Struct\Plugin
$shopwarePath string
    private function checkForNewStructure(Plugin $plugin, $shopwarePath)
    {
        $path = $shopwarePath . '/engine/Shopware/Plugins/Local/';
        $pluginName = $plugin->name;
        $destPath = $plugin->module . '/' . $pluginName;
        $absPath = $path . '/' . $destPath;
        if (file_exists($absPath . '/Bootstrap.php')) {
            return;
        }
        rename($absPath, $shopwarePath . '/custom/plugins/' . $pluginName);
    }