protected function setIsDraftSecured(Session $session, $secured)
    {
        // Versioned >=1.2
        if (method_exists(Versioned::class, 'set_draft_site_secured')) {
            Versioned::set_draft_site_secured($secured);
        }

        // Set session variable anyway
        $session->set('unsecuredDraftSite', !$secured);
    }
protected function setIsDraftSecured(Session $session, $secured)
    {
        // Versioned >=1.2
        if (method_exists(Versioned::class, 'set_draft_site_secured')) {
            Versioned::set_draft_site_secured($secured);
        }

        // Set session variable anyway
        $session->set('unsecuredDraftSite', !$secured);
    }
protected function setIsDraftSecured ( Session $ session , $ secured ) { // Versioned >=1.2 if ( method_exists ( Versioned :: class , 'set_draft_site_secured' ) ) { Versioned :: set_draft_site_secured ( $ secured ) ; } // Set session variable anyway $ session -> set ( 'unsecuredDraftSite' , ! $ secured ) ; }
Set draft site security

@param Session $session
@param bool $secured True if draft site should be secured
Set draft site security