File tree Expand file tree Collapse file tree 1 file changed +0
-4
lines changed Expand file tree Collapse file tree 1 file changed +0
-4
lines changed Original file line number Diff line number Diff line change @@ -46,14 +46,10 @@ Response = (function () {
4646 }
4747 Response . prototype . job_attach = function ( ...attachments ) {
4848 const requiredLabels = [ 'type' , 'label' , 'value' ]
49- const allowedTypes = [ 'link' , 'password' ]
5049 for ( const attachment of attachments ) {
5150 if ( ! ~ requiredLabels . every ( l => ~ Object . keys ( attachment ) . indexOf ( l ) ) ) {
5251 throw new Error ( `Attachment requires mandatory properties ${ requiredLabels . join ( ', ' ) } ` )
5352 }
54- if ( ! ~ allowedTypes . indexOf ( attachment . type ) ) {
55- throw new Error ( `Attachment must be of one of the following types ${ allowedTypes . join ( ', ' ) } ` )
56- }
5753 }
5854 this . _attachments . push ( ...attachments )
5955 this . meta ( 'set_job_attachments' , JSON . stringify ( this . _attachments ) )
You can’t perform that action at this time.
0 commit comments