Skip to content

Commit

Permalink
Remove unused fromMapToRecord
Browse files Browse the repository at this point in the history
  • Loading branch information
jbcrail committed Aug 30, 2023
1 parent 88f6111 commit 40b82e3
Showing 1 changed file with 0 additions and 12 deletions.
12 changes: 0 additions & 12 deletions x-pack/plugins/profiling/common/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,18 +41,6 @@ export function timeRangeFromRequest(request: any): [number, number] {
return [timeFrom, timeTo];
}

// Converts from a Map object to a Record object since Map objects are not
// serializable to JSON by default
export function fromMapToRecord<K extends string, V>(m: Map<K, V>): Record<string, V> {
const output: Record<string, V> = {};

for (const [key, value] of m) {
output[key] = value;
}

return output;
}

export const NOT_AVAILABLE_LABEL = i18n.translate('xpack.profiling.notAvailableLabel', {
defaultMessage: 'N/A',
});

0 comments on commit 40b82e3

Please sign in to comment.