@@ -134,36 +134,21 @@ private function fetchExtensionYmlData(string $mainExtensionYmlUrl, string $gith
134134 $ pluginData ['images ' ][] = $ githubUrl . '/ ' . $ images ['file ' ];
135135 }
136136 }
137- if (isset ($ extensionYmlData ['store ' ]['description ' ]['en ' ])) {
138- $ pluginData ['description ' ]['en-GB ' ] = $ this ->processFileUrls (
139- $ extensionYmlData ['store ' ]['description ' ]['en ' ],
140- $ githubUrl
141- );
137+ if (isset ($ extensionYmlData ['store ' ]['description ' ]['en ' ])
138+ && !str_starts_with ($ extensionYmlData ['store ' ]['description ' ]['en ' ], 'file: ' )
139+ ) {
140+ $ pluginData ['description ' ]['en-GB ' ] = $ extensionYmlData ['store ' ]['description ' ]['en ' ];
142141 }
143- if (isset ($ extensionYmlData ['store ' ]['description ' ]['de ' ])) {
144- $ pluginData ['description ' ]['de-DE ' ] = $ this ->processFileUrls (
145- $ extensionYmlData ['store ' ]['description ' ]['de ' ],
146- $ githubUrl
147- );
142+ if (isset ($ extensionYmlData ['store ' ]['description ' ]['de ' ])
143+ && !str_starts_with ($ extensionYmlData ['store ' ]['description ' ]['de ' ], 'file: ' )
144+ ) {
145+ $ pluginData ['description ' ]['de-DE ' ] = $ extensionYmlData ['store ' ]['description ' ]['de ' ];
148146 }
149-
150- // TODO Load from markdown files
151-
152- // TODO load images from folder
153147 }
154148
155149 return $ pluginData ;
156150 }
157151
158- private function processFileUrls (string $ data , string $ githubUrl ): string
159- {
160- if (str_starts_with ($ data , 'file: ' )) {
161- return $ githubUrl . '/ ' . substr ($ data , 5 );
162- }
163-
164- return $ data ;
165- }
166-
167152 private function findSuitableVersion (array $ packagistData ): ?array
168153 {
169154 $ versions = $ packagistData ['package ' ]['versions ' ];
0 commit comments