index.tsx 594 B

12345678910111213141516171819202122
  1. import Feature from 'sentry/components/acl/feature';
  2. import useOrganization from 'sentry/utils/useOrganization';
  3. import RelayWrapper from './relayWrapper';
  4. function OrganizationRelay(props: Omit<RelayWrapper['props'], 'organization'>) {
  5. const organization = useOrganization();
  6. return (
  7. <Feature
  8. organization={organization}
  9. features={['relay']}
  10. hookName="feature-disabled:relay"
  11. >
  12. <RelayWrapper
  13. organization={organization as RelayWrapper['props']['organization']}
  14. {...props}
  15. />
  16. </Feature>
  17. );
  18. }
  19. export default OrganizationRelay;