File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -4,9 +4,12 @@ import * as Sentry from '@sentry/react';
4
4
import DevToolbar from 'sentry/components/devtoolbar' ;
5
5
import { rawTrackAnalyticsEvent } from 'sentry/utils/analytics' ;
6
6
import useOrganization from 'sentry/utils/useOrganization' ;
7
+ import { useUser } from 'sentry/utils/useUser' ;
7
8
8
9
export default function useDevToolbar ( { enabled} : { enabled : boolean } ) {
9
10
const organization = useOrganization ( ) ;
11
+ const { email} = useUser ( ) ;
12
+
10
13
useEffect ( ( ) => {
11
14
if ( enabled ) {
12
15
// TODO: this is insufficient and doesn't take into account control/silo endpoints
@@ -30,13 +33,13 @@ export default function useDevToolbar({enabled}: {enabled: boolean}) {
30
33
`https://github.com/search?q=repo%3Agetsentry%2Fsentry-options-automator+OR+repo%3Agetsentry%2Fsentry+${ flag } &type=code` ,
31
34
32
35
trackAnalytics : ( props : { eventKey : string ; eventName : string } ) =>
33
- rawTrackAnalyticsEvent ( { ...props , organization} ) ,
36
+ rawTrackAnalyticsEvent ( { ...props , email , organization} ) ,
34
37
} ) ;
35
38
36
39
return ( ) => {
37
40
promise . then ( cleanup => cleanup ( ) ) ;
38
41
} ;
39
42
}
40
43
return ( ) => { } ;
41
- } , [ enabled , organization ] ) ;
44
+ } , [ email , enabled , organization ] ) ;
42
45
}
You can’t perform that action at this time.
0 commit comments