public static function AuthHelper::getTenantCdn in Auth0 Single Sign On 8.2
Get the tenant CDN base URL based on the Application domain.
Parameters
string $domain: Tenant domain.
Return value
string Tenant CDN base URL
File
- src/
Util/ AuthHelper.php, line 161 - Contains \Drupal\auth0\Util\AuthHelper.
Class
- AuthHelper
- Controller routines for auth0 authentication.
Namespace
Drupal\auth0\UtilCode
public static function getTenantCdn($domain) {
preg_match('/^[\\w\\d\\-_0-9]+\\.([\\w\\d\\-_0-9]*)[\\.]*auth0\\.com$/', $domain, $matches);
return 'https://cdn' . (empty($matches[1]) || $matches[1] == 'us' ? '' : '.' . $matches[1]) . '.auth0.com';
}