We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e7b673c commit c8414d4Copy full SHA for c8414d4
1 file changed
src/Controller/ShopwareFilesController.php
@@ -109,7 +109,17 @@ public function restoreShopwareFile(Request $request): JsonResponse
109
private function getShopwareUrl(string $name): ?string
110
{
111
$name = preg_replace('/^vendor\/shopware\//', '', $name);
112
- return 'https://github.com/shopware/platform/blob/v' . $this->shopwareVersion . '/src/' . ucfirst($name);
+
113
+ $pathParts = \explode('/', $name);
114
+ $repo = $pathParts[0];
115
+ array_shift($pathParts);
116
117
+ return 'https://github.com/shopware/' .
118
+ $repo .
119
+ '/blob/v' .
120
+ $this->shopwareVersion .
121
+ '/' .
122
+ \implode('/', $pathParts);
123
}
124
125
private function getOriginalFileContent(string $name): ?string
0 commit comments