Navigation Menu

Skip to content

Commit

Permalink
documentation tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Oct 20, 2013
1 parent 1c394f3 commit a7f13df
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions lib/Mojo/Path.pm
Expand Up @@ -81,7 +81,7 @@ sub to_abs_string {
sub to_dir {
my $clone = shift->clone;
pop @{$clone->parts} unless $clone->trailing_slash;
return $clone->trailing_slash(@{$clone->parts} ? 1 : 0);
return $clone->trailing_slash(!!@{$clone->parts});
}

sub to_route {
Expand Down Expand Up @@ -216,8 +216,8 @@ Check if path contains given prefix.
=head2 leading_slash
my $slash = $path->leading_slash;
$path = $path->leading_slash(1);
my $bool = $path->leading_slash;
$path = $path->leading_slash($bool);
Path has a leading slash. Note that this method will normalize the path and
that C<%2F> will be treated as C</> for security reasons.
Expand Down Expand Up @@ -304,8 +304,8 @@ Turn path into a string.
=head2 trailing_slash
my $slash = $path->trailing_slash;
$path = $path->trailing_slash(1);
my $bool = $path->trailing_slash;
$path = $path->trailing_slash($bool);
Path has a trailing slash. Note that this method will normalize the path and
that C<%2F> will be treated as C</> for security reasons.
Expand Down
2 changes: 1 addition & 1 deletion lib/Mojo/UserAgent.pm
Expand Up @@ -171,7 +171,7 @@ sub _connect {
local_address => $self->local_address,
port => $port,
timeout => $self->connect_timeout,
tls => $proto eq 'https' ? 1 : 0,
tls => $proto eq 'https',
tls_ca => $self->ca,
tls_cert => $self->cert,
tls_key => $self->key,
Expand Down

0 comments on commit a7f13df

Please sign in to comment.