Skip to content

Commit

Permalink
Refactor accessors.tsx
Browse files Browse the repository at this point in the history
  • Loading branch information
DianaDerevyankina committed Mar 1, 2021
1 parent 1f9273c commit f2b088e
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/plugins/vis_type_xy/public/utils/accessors.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ const getFieldName = (fieldName: string, index?: number) => {
};

export const isRangeAggType = (type: string | null) =>
type === BUCKET_TYPES.DATE_RANGE || type === BUCKET_TYPES.RANGE || type === BUCKET_TYPES.IP_RANGE;
[BUCKET_TYPES.DATE_RANGE, BUCKET_TYPES.RANGE, BUCKET_TYPES.IP_RANGE].includes(
type as BUCKET_TYPES
);

/**
* Returns accessor function for complex accessor types
Expand Down

0 comments on commit f2b088e

Please sign in to comment.