mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-21 23:43:17 +01:00
Filemanager: Try to avoid type error in list when mime is missing
Uncaught TypeError: Cannot read properties of null (reading 'mime_odf_regex') at collaboraFilemanagerAPP.isEditable (filemanager.ts:1566:38)
This commit is contained in:
parent
4420e9662d
commit
d54eb8e388
@ -1559,7 +1559,10 @@ export class filemanagerAPP extends EgwApp
|
||||
let data = egw.dataGetUIDdata(_senders[0].id);
|
||||
let mime = this.et2.getInstanceManager().widgetContainer.getWidgetById('$row');
|
||||
let fe = egw.file_editor_prefered_mimes(data.data.mime);
|
||||
if (fe && fe.mime && !fe.mime[data.data.mime]) return false;
|
||||
if(!mime || fe && fe.mime && !fe.mime[data.data.mime])
|
||||
{
|
||||
return false;
|
||||
}
|
||||
return !!data.data.mime.match(mime.mime_odf_regex);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user