File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -172,11 +172,13 @@ private function resolveExtensionIcons(array $extensionKeys): array
172172 if (!$ this ->packageManager ->isPackageActive ($ key )) {
173173 continue ;
174174 }
175- $ iconPath = $ this ->packageManager ->getPackage ($ key )->getPackageIcon ();
176- if ($ iconPath !== null ) {
177- $ icons [$ key ] = PathUtility::getAbsoluteWebPath (
178- $ this ->packageManager ->getPackage ($ key )->getPackagePath () . $ iconPath
179- );
175+ $ packagePath = $ this ->packageManager ->getPackage ($ key )->getPackagePath ();
176+ foreach (['svg ' , 'png ' , 'gif ' ] as $ extension ) {
177+ $ relativeIconPath = 'Resources/Public/Icons/Extension. ' . $ extension ;
178+ if (file_exists ($ packagePath . $ relativeIconPath )) {
179+ $ icons [$ key ] = PathUtility::getAbsoluteWebPath ($ packagePath . $ relativeIconPath );
180+ break ;
181+ }
180182 }
181183 }
182184 return $ icons ;
You can’t perform that action at this time.
0 commit comments