Skip to content

Commit

Permalink
Merge pull request #203 from zoffixznet/patch-2
Browse files Browse the repository at this point in the history
Use cheaper conditional
  • Loading branch information
Filip Sergot authored Jun 25, 2018
2 parents 5cfe7ea + 1d21df7 commit 06a70d5
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/HTTP/Request.pm6
Original file line number Diff line number Diff line change
Expand Up @@ -282,9 +282,7 @@ method make-boundary(int $size=10) {


method Str (:$debug, Bool :$bin) {
if $.file !~~ /^\// {
$.file = '/' ~ $.file;
}
$.file = '/' ~ $.file unless $.file.starts-with: '/';
my $s = "$.method $.file $.protocol";
$s ~= $CRLF ~ callwith($CRLF, :debug($debug), :$bin);
}
Expand Down

0 comments on commit 06a70d5

Please sign in to comment.