If the key is not provided, do not send an empty key
authorMarius Gavrilescu <marius@ieval.ro>
Sat, 11 Oct 2014 22:32:03 +0000 (01:32 +0300)
committerMarius Gavrilescu <marius@ieval.ro>
Sat, 11 Oct 2014 22:32:03 +0000 (01:32 +0300)
lib/WWW/BackpackTF.pm

index 5e33b57d67e0055394290ac18fd4d5d7e83003ce..0b6ac12490f1d5277451789ce20f4cd1ef5bbe88 100644 (file)
@@ -31,7 +31,7 @@ use WWW::BackpackTF::User;
 
 sub request {
        my ($self, $url, %params) = @_;
-       $params{key} = $self->{key};
+       $params{key} = $self->{key} if $self->{key};
        $url = $self->{base} . $url;
        $url .= "&$_=$params{$_}" for keys %params;
        my $response = decode_json(get $url)->{response};
This page took 0.010289 seconds and 4 git commands to generate.