Skip to content

Commit 0c76cab

Browse files
authored
feat(Prevent): add correct link to integrated org button (#97738)
This PR adds correct link to the integrated org button, also making it external and adjusting a constant value from another PR I mistakenly thought I pushed to 😬. Replaces [this](#97736) Closes https://linear.app/getsentry/issue/CCMRG-1505/enable-functionality-for-integrated-org-button
1 parent c689c09 commit 0c76cab

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

static/app/components/prevent/integratedOrgSelector/integratedOrgSelector.tsx

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,11 @@ import {IconIntegratedOrg} from './iconIntegratedOrg';
2121
function AddIntegratedOrgButton() {
2222
return (
2323
<LinkButton
24-
href="https://github.com/apps/sentry-io"
24+
href="https://github.com/apps/sentry/installations/select_target"
2525
size="sm"
2626
icon={<IconAdd size="sm" />}
2727
priority="default"
28+
external
2829
>
2930
{t('Integrated Organization')}
3031
</LinkButton>
@@ -107,8 +108,7 @@ export function IntegratedOrgSelector() {
107108
<IconIntegratedOrg />
108109
</IconContainer>
109110
<TriggerLabel>
110-
{integratedOrgIdToName(integratedOrgId, integrations) ||
111-
t('Select integrated organization')}
111+
{integratedOrgIdToName(integratedOrgId, integrations)}
112112
</TriggerLabel>
113113
</Flex>
114114
</TriggerLabelWrap>
Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1+
import {t} from 'sentry/locale';
12
import type {Integration} from 'sentry/types/integrations';
23

34
export const integratedOrgIdToName = (id?: string, integrations?: Integration[]) => {
45
if (!id || !integrations) {
5-
return 'No Integration';
6+
return t('Select Integrated Org');
67
}
78
const result = integrations.find(item => item.id === id);
8-
return result ? result.name : 'Select Integration';
9+
return result?.name || t('Select Integrated Org');
910
};

0 commit comments

Comments
 (0)