Skip to content

Commit

Permalink
some missed changes to Cpanel::JSON::XS
Browse files Browse the repository at this point in the history
  • Loading branch information
mickeyn committed Apr 23, 2016
1 parent 04f4733 commit e0d2e9d
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 0 additions & 2 deletions cpanfile
Expand Up @@ -74,8 +74,6 @@ requires 'IO::String';
requires 'IO::Uncompress::Bunzip2';
requires 'IO::Zlib';
requires 'IPC::Run3';
requires 'JSON::XS', '3.01';
requires 'JSON', '2.90';
requires 'LWP::Protocol::https';
requires 'LWP::UserAgent', '6.15';
requires 'LWP::UserAgent::Paranoid';
Expand Down
3 changes: 2 additions & 1 deletion lib/MetaCPAN/Script/Author.pm
Expand Up @@ -115,7 +115,8 @@ sub author_config {

my $author;
eval {
$author = JSON::XS->new->utf8->relaxed->decode( $file->slurp );
$author
= Cpanel::JSON::XS->new->utf8->relaxed->decode( $file->slurp );
1;
} or do {
log_warn {"$file is broken: $@"};
Expand Down
2 changes: 1 addition & 1 deletion lib/MetaCPAN/Script/Mirrors.pm
Expand Up @@ -24,7 +24,7 @@ sub index_mirrors {

my $json = $self->cpan->file( 'indices', 'mirrors.json' )->slurp;
my $type = $self->index->type('mirror');
my $mirrors = JSON::XS::decode_json($json);
my $mirrors = Cpanel::JSON::XS::decode_json($json);
foreach my $mirror (@$mirrors) {
$mirror->{location}
= { lon => $mirror->{longitude}, lat => $mirror->{latitude} };
Expand Down
3 changes: 2 additions & 1 deletion lib/MetaCPAN/Script/Query.pm
Expand Up @@ -41,7 +41,8 @@ sub run {
}
);
my @results = dpath($path)->match( decode_json($json) );
( my $dump = Dump(@results) ) =~ s/\!\!perl\/scalar:JSON::XS::Boolean //g;
( my $dump = Dump(@results) )
=~ s/\!\!perl\/scalar:Cpanel::JSON::XS::Boolean //g;
print $dump;

}
Expand Down
2 changes: 1 addition & 1 deletion lib/MetaCPAN/Script/Release.pm
Expand Up @@ -4,7 +4,7 @@ use strict;
use warnings;

BEGIN {
$ENV{PERL_JSON_BACKEND} = 'JSON::XS';
$ENV{PERL_JSON_BACKEND} = 'Cpanel::JSON::XS';
}

use CPAN::DistnameInfo ();
Expand Down

0 comments on commit e0d2e9d

Please sign in to comment.