Skip to content
This repository was archived by the owner on Jan 13, 2022. It is now read-only.

Commit e5d4c3e

Browse files
committed
Merge pull request #328 from jkrasnoo/4.0-dev
Curl handler check
2 parents ebc8266 + eb74731 commit e5d4c3e

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/Facebook/HttpClients/FacebookCurl.php

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,14 +35,16 @@ class FacebookCurl
3535
/**
3636
* @var resource Curl resource instance
3737
*/
38-
protected $curl;
38+
protected $curl = null;
3939

4040
/**
4141
* Make a new curl reference instance
4242
*/
4343
public function init()
4444
{
45-
$this->curl = curl_init();
45+
if ($this->curl === null) {
46+
$this->curl = curl_init();
47+
}
4648
}
4749

4850
/**

0 commit comments

Comments
 (0)