Skip to content

Commit

Permalink
tweak: safely check presence of current protocol (#171)
Browse files Browse the repository at this point in the history
  • Loading branch information
g105b authored Sep 26, 2022
1 parent 6f1ac12 commit 2cf71d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Message.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ public function withProtocolVersion($version) {

$clone = clone $this;

if(strstr($clone->protocol, "/")) {
if(isset($clone->protocol) && strstr($clone->protocol, "/")) {
$versionStartPos = strpos(
$clone->protocol,
"/"
Expand Down

0 comments on commit 2cf71d3

Please sign in to comment.