Initial class construction
This commit is contained in:
27
Git/usr/share/perl5/vendor_perl/URI/http.pm
Normal file
27
Git/usr/share/perl5/vendor_perl/URI/http.pm
Normal file
@ -0,0 +1,27 @@
|
||||
package URI::http;
|
||||
|
||||
use strict;
|
||||
use warnings;
|
||||
|
||||
our $VERSION = '1.76';
|
||||
|
||||
use parent 'URI::_server';
|
||||
|
||||
sub default_port { 80 }
|
||||
|
||||
sub canonical
|
||||
{
|
||||
my $self = shift;
|
||||
my $other = $self->SUPER::canonical;
|
||||
|
||||
my $slash_path = defined($other->authority) &&
|
||||
!length($other->path) && !defined($other->query);
|
||||
|
||||
if ($slash_path) {
|
||||
$other = $other->clone if $other == $self;
|
||||
$other->path("/");
|
||||
}
|
||||
$other;
|
||||
}
|
||||
|
||||
1;
|
Reference in New Issue
Block a user