Skip to content

Commit

Permalink
Merge pull request #5 from daydaygo/master
Browse files Browse the repository at this point in the history
add http2
  • Loading branch information
huangzhhui authored Mar 9, 2018
2 parents c27b40a + 614629a commit 81ab4ce
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/Http/HttpServer.php
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,9 @@ class HttpServer extends AbstractServer
*/
public function start()
{
if (!empty($this->setting['open_http2_protocol'])) {
$this->httpSetting['type'] = SWOOLE_SOCK_TCP|SWOOLE_SSL;
}
$this->server = new Server($this->httpSetting['host'], $this->httpSetting['port'], $this->httpSetting['mode'], $this->httpSetting['type']);

// Bind event callback
Expand Down

0 comments on commit 81ab4ce

Please sign in to comment.