diff --git a/src/legacy/core_plugins/metrics/server/lib/vis_data/__tests__/helpers/bucket_transform.js b/src/legacy/core_plugins/metrics/server/lib/vis_data/__tests__/helpers/bucket_transform.js index e0db2422f80b4..8edb7cd77f603 100644 --- a/src/legacy/core_plugins/metrics/server/lib/vis_data/__tests__/helpers/bucket_transform.js +++ b/src/legacy/core_plugins/metrics/server/lib/vis_data/__tests__/helpers/bucket_transform.js @@ -437,7 +437,7 @@ describe('bucketTransform', () => { }, gap_policy: 'skip', script: { - source: 'params.value > 0 ? params.value : 0', + source: 'params.value > 0.0 ? params.value : 0.0', lang: 'painless' } } diff --git a/src/legacy/core_plugins/metrics/server/lib/vis_data/helpers/bucket_transform.js b/src/legacy/core_plugins/metrics/server/lib/vis_data/helpers/bucket_transform.js index c487e541beb39..459da1a3d8486 100644 --- a/src/legacy/core_plugins/metrics/server/lib/vis_data/helpers/bucket_transform.js +++ b/src/legacy/core_plugins/metrics/server/lib/vis_data/helpers/bucket_transform.js @@ -252,7 +252,7 @@ export default { value: getBucketsPath(bucket.field, metrics), }, script: { - source: 'params.value > 0 ? params.value : 0', + source: 'params.value > 0.0 ? params.value : 0.0', lang: 'painless', }, gap_policy: 'skip', // seems sane