public function ChainLocaleResolver::resolve in Commerce Core 8.2
Resolves the locale.
Return value
\Drupal\commerce\Locale|null The locale object, if resolved. Otherwise NULL, indicating that the next resolver in the chain should be called.
Overrides LocaleResolverInterface::resolve
File
- src/
Resolver/ ChainLocaleResolver.php, line 44
Class
- ChainLocaleResolver
- Default implementation of the chain locale resolver.
Namespace
Drupal\commerce\ResolverCode
public function resolve() {
foreach ($this->resolvers as $resolver) {
$result = $resolver
->resolve();
if ($result) {
return $result;
}
}
}