hasThresholdValue.tsx 272 B

123456789101112
  1. import {defined} from 'sentry/utils';
  2. /**
  3. * A threshold has a value if it is not one of the following:
  4. *
  5. * '', null, undefined
  6. *
  7. *
  8. */
  9. export default function hasThresholdValue(value: number | '' | null): value is number {
  10. return defined(value) && value !== '';
  11. }