Remove Object.assign call. (#33860)

This commit is contained in:
Justin Kambic 2019-04-11 14:58:02 -04:00 committed by GitHub
parent b7871a5532
commit f234661825
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -33,13 +33,10 @@ export function formatEsBucketsForHistogram<T extends UMESBucket>(
const nextItem = array[index + 1];
const bucketSize = nextItem ? Math.abs(nextItem.key - key) : Math.abs(terminalBucketTime - key);
return Object.assign(
{},
{
x: key + bucketSize,
x0: key,
},
item
);
return {
x: key + bucketSize,
x0: key,
...item,
};
});
}