public function activate(Selector $listener, string $type, string $id)
    {
        $theme = $this->getAvailableTheme($type)->get($id);

        if (! in_array($type, $this->type) || is_null($theme)) {
            return $listener->themeFailedVerification();
        }

        $this->memory->put("site.theme.{$type}", $id);

        return $listener->themeHasActivated($type, $id);
    }
public function activate(Selector $listener, string $type, string $id)
    {
        $theme = $this->getAvailableTheme($type)->get($id);

        if (! in_array($type, $this->type) || is_null($theme)) {
            return $listener->themeFailedVerification();
        }

        $this->memory->put("site.theme.{$type}", $id);

        return $listener->themeHasActivated($type, $id);
    }
public function activate ( Selector $ listener , string $ type , string $ id ) { $ theme = $ this -> getAvailableTheme ( $ type ) -> get ( $ id ) ; if ( ! in_array ( $ type , $ this -> type ) || is_null ( $ theme ) ) { return $ listener -> themeFailedVerification ( ) ; } $ this -> memory -> put ( "site.theme.{$type}" , $ id ) ; return $ listener -> themeHasActivated ( $ type , $ id ) ; }
Activate a theme.

@param  \Orchestra\Contracts\Theme\Listener\Selector  $listener
@param  string  $type
@param  string  $id

@return mixed
Activate a theme .