Skip to content

Commit 1294717

Browse files
Revert "Helm.pm: keep boolean in fields like "deprecated" if JSON::XS is available"
This reverts commit c9e98cc.
1 parent c9e98cc commit 1294717

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

Build/Helm.pm

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@ use strict;
2525
use Build::SimpleJSON;
2626

2727
eval { require YAML::XS; $YAML::XS::LoadBlessed = 0; };
28-
my $jsonxs = eval { require JSON::XS; return 1 };
29-
3028
*YAML::XS::LoadFile = sub {die("YAML::XS is not available\n")} unless defined &YAML::XS::LoadFile;
3129

3230
sub verify_config {
@@ -111,17 +109,9 @@ sub show {
111109
die("$fn: $!\n") unless open($fd, '<', $fn);
112110
1 while sysread($fd, $config_yaml, 8192, length($config_yaml));
113111
close($fd);
114-
local $YAML::XS::Boolean = "boolean";
115112
my $config = YAML::XS::Load($config_yaml);
116113
verify_config($config);
117-
my $config_json;
118-
if ($jsonxs) {
119-
my $convert = JSON::XS->new->utf8->canonical->pretty;
120-
$convert = $convert->convert_blessed(1);
121-
$config_json = $convert->encode($config);
122-
} else {
123-
$config_json = Build::SimpleJSON::unparse($config)."\n";
124-
}
114+
my $config_json = Build::SimpleJSON::unparse($config)."\n";
125115
my $helminfo = {};
126116
$helminfo->{'name'} = $d->{'name'};
127117
$helminfo->{'version'} = $d->{'version'};

0 commit comments

Comments
 (0)