You are here

public function DefaultStoreResolver::resolve in Commerce Core 8.2

Resolves the store.

Return value

\Drupal\commerce_store\Entity\StoreInterface|null The store, if resolved. Otherwise NULL, indicating that the next resolver in the chain should be called.

Overrides StoreResolverInterface::resolve

File

modules/store/src/Resolver/DefaultStoreResolver.php, line 32

Class

DefaultStoreResolver
Returns the default store, if known.

Namespace

Drupal\commerce_store\Resolver

Code

public function resolve() {
  return $this->storage
    ->loadDefault();
}