Commit de29ee23 authored by Matthieu Muffato's avatar Matthieu Muffato
Browse files

Numbers are returned as real numbers, not strings;

This is needed for pipeline_wide_parameters as each value is destringified
independently and the JSON writer would otherwise force writing numbers as
strings
parent 321e4b53
......@@ -55,6 +55,7 @@ use strict;
use warnings;
use Carp ('confess');
use Data::Dumper;
use Scalar::Util qw(looks_like_number);
use Bio::EnsEMBL::Hive::Version;
use Bio::EnsEMBL::Hive::DBSQL::SqlSchemaAdaptor;
#use Bio::EnsEMBL::Hive::DBSQL::DBConnection; # causes warnings that all exported functions have been redefined
......@@ -109,6 +110,7 @@ sub destringify {
or $value=~/^".*"$/
or $value=~/^{.*}$/
or $value=~/^\[.*\]$/
or looks_like_number($value) # Needed for pipeline_wide_parameters as each value is destringified independently and the JSON writer would otherwise force writing numbers as strings
or $value eq 'undef') {
$value = eval($value);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment