Skip to content

Commit

Permalink
Slight refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
davorg committed Jun 2, 2015
1 parent 25f82a4 commit e23e536
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions gettemp
Expand Up @@ -12,11 +12,9 @@ my $base_url = 'https://api.hivehome.com/v5/';

my ($user, $pass) = @ARGV;

my $ua = LWP::UserAgent->new;
$ua->cookie_jar(HTTP::Cookies->new(
file => 'hive_cookies.txt',
autosave => 1,
));
my $ua = LWP::UserAgent->new(
cookie_jar => HTTP::Cookies->new,
);

my $req = POST "$base_url/login",
[ username => $user, password => $pass ];
Expand Down

0 comments on commit e23e536

Please sign in to comment.