make local vars local

master
Benjamin Schieder 2017-04-23 20:24:03 +01:00
parent cf4f398f8e
commit 70c6a792db
5 changed files with 7 additions and 7 deletions

View File

@ -21,7 +21,7 @@ sub get_or_create_by_instance {
open(DATA, "./register_app.bash '$main::config->{app}->{client_name}' '$main::config->{app}->{redirect_uris}' '$main::config->{app}->{website}' '$instance'|");
my $reply = "";
{
$/ = undef;
local $/ = undef;
$reply = <DATA>;
}
close DATA;

View File

@ -26,7 +26,7 @@ sub authenticate {
open(DATA, "./verify_credentials.bash '$token' '$instance'|");
my $reply;
{
$/ = undef;
local $/ = undef;
$reply = <DATA>
}
close DATA;

View File

@ -34,7 +34,7 @@ sub prerender {
open(DATA, "./process_code.bash '$app->{data}->{instance_client_id}' '$app->{data}->{instance_client_secret}' '$main::FORM{code}' '$main::config->{app}->{redirect_uris}' '$instance'|");
my $reply;
{
$/ = undef;
local $/ = undef;
$reply = <DATA>;
}
close DATA;
@ -47,7 +47,7 @@ sub prerender {
my $token = $$reply{access_token};
open(DATA, "./verify_credentials.bash '$token' '$instance'|");
{
$/ = undef;
local $/ = undef;
$reply = <DATA>
}
close DATA;

View File

@ -11,7 +11,7 @@ use RSSTootalizer::Entry;
our $config = "";
open CONFIG, "rsstootalizer.conf.json" or die "Cannot open rsstootalizer.conf.json";
{
$/ = undef;
local $/ = undef;
$config = <CONFIG>;
}
close CONFIG;
@ -67,7 +67,7 @@ FEED: foreach my $feed (@feeds){
open(DATA, "./post_status.bash '$user->{data}->{access_token}' '$user->{data}->{instance}' '$status'|");
my $reply = "";
{
$/ = undef;
local $/ = undef;
$reply = <DATA>;
}

View File

@ -13,7 +13,7 @@ our $CURRENTUSER;
our $config = "";
open CONFIG, "rsstootalizer.conf.json" or die "Cannot open rsstootalizer.conf.json";
{
$/ = undef;
local $/ = undef;
$config = <CONFIG>;
}
close CONFIG;