The communications platform that puts data protection first.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
Rocket.Chat/packages/rocketchat-file-upload/lib/FileUploadBase.js

39 lines
587 B

/* globals FileUploadBase:true, UploadFS */
/* exported FileUploadBase */
UploadFS.config.defaultStorePermissions = new UploadFS.StorePermissions({
insert: function(userId/*, doc*/) {
return userId;
},
update: function(userId, doc) {
return userId === doc.userId;
},
remove: function(userId, doc) {
return userId === doc.userId;
}
});
FileUploadBase = class FileUploadBase {
constructor(meta, file) {
this.id = Random.id();
this.meta = meta;
this.file = file;
}
getProgress() {
}
getFileName() {
return this.meta.name;
}
start() {
}
stop() {
}
};