Google\Spreadsheet\DefaultServiceRequest::setSslVerifyPeer PHP Method

setSslVerifyPeer() public method

Verify the peer"s ssl certificate
public setSslVerifyPeer ( boolean $sslVerifyPeer ) : DefaultServiceRequest
$sslVerifyPeer boolean
return DefaultServiceRequest
    public function setSslVerifyPeer($sslVerifyPeer)
    {
        $this->curlParams[CURLOPT_SSL_VERIFYPEER] = (bool) $sslVerifyPeer;
        return $this;
    }

Usage Example

 public function testSetSslVerifyPeer()
 {
     $request = new DefaultServiceRequest("token");
     $this->assertTrue($request->setSslVerifyPeer(false) instanceof DefaultServiceRequest);
     $this->assertFalse($request->getSslVerifyPeer());
 }