Skip to content
Snippets Groups Projects
Commit c517994c authored by George Secrieru's avatar George Secrieru
Browse files

Adding support for all files (i.e. empty white list)

parent 7303c99b
No related merge requests found
......@@ -12,12 +12,14 @@ if UploadFS?
fileUploadMediaWhiteList = ->
return unless RocketChat.settings.get('FileUpload_MediaTypeWhiteList')
return _.map(RocketChat.settings.get('FileUpload_MediaTypeWhiteList').split(','), (item) -> return item.trim() )
@fileUploadIsValidContentType = (type) ->
list = fileUploadMediaWhiteList()
if _.contains list, type
if !list or _.contains list, type
return true
else
wildCardGlob = '/*'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment