File tree Expand file tree Collapse file tree 3 files changed +11
-3
lines changed Expand file tree Collapse file tree 3 files changed +11
-3
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ const ATTACHMENT_ENVELOPE = createEnvelope<EventEnvelope>(
22
22
length : 20 ,
23
23
filename : 'test-file.txt' ,
24
24
content_type : 'text/plain' ,
25
- attachment_type : 'text ' ,
25
+ attachment_type : 'event.attachment ' ,
26
26
} ,
27
27
'attachment content' ,
28
28
] as AttachmentItem ,
Original file line number Diff line number Diff line change
1
+ export type AttachmentType =
2
+ | 'event.attachment'
3
+ | 'event.minidump'
4
+ | 'event.applecrashreport'
5
+ | 'unreal.context'
6
+ | 'unreal.logs' ;
7
+
1
8
/**
2
9
* An attachment to an event. This is used to upload arbitrary data to Sentry.
3
10
*
@@ -23,5 +30,5 @@ export interface Attachment {
23
30
/**
24
31
* The type of the attachment. Defaults to `event.attachment` if not specified.
25
32
*/
26
- attachmentType ?: 'event.attachment' | 'event.minidump' | 'event.applecrashreport' | 'unreal.context' | 'unreal.logs' ;
33
+ attachmentType ?: AttachmentType ;
27
34
}
Original file line number Diff line number Diff line change
1
+ import type { AttachmentType } from './attachment' ;
1
2
import type { SerializedCheckIn } from './checkin' ;
2
3
import type { ClientReport } from './clientreport' ;
3
4
import type { DsnComponents } from './dsn' ;
@@ -66,7 +67,7 @@ type AttachmentItemHeaders = {
66
67
length : number ;
67
68
filename : string ;
68
69
content_type ?: string ;
69
- attachment_type ?: string ;
70
+ attachment_type ?: AttachmentType ;
70
71
} ;
71
72
type UserFeedbackItemHeaders = { type : 'user_report' } ;
72
73
type FeedbackItemHeaders = { type : 'feedback' } ;
You can’t perform that action at this time.
0 commit comments