public static function LibrariesCdn::find in Libraries CDN API 8
Same name and namespace in other branches
- 7 src/LibrariesCDN.php \Drupal\libraries_cdn\LibrariesCDN::find()
Return CDN Plugin id's of the CDN who provides a library.
Parameters
string $library: The library to search.
Return value
array $providers The array of providers who provides the searched library.
File
- src/
LibrariesCdn.php, line 58 - Contains LibrariesCdn.
Class
- LibrariesCdn
- Class LibrariesCdn.
Namespace
Drupal\libraries_cdnCode
public static function find($library) {
$providers = array();
foreach (self::getAvailableCdn() as $cdn) {
self::setPlugin($cdn, $library);
if (self::isAvailable()) {
$providers[] = $cdn;
}
}
return $providers;
}