mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-12-27 00:58:55 +01:00
* Mail - avoid javascript error blocking context menu from SpamTitan check when row data not found
This commit is contained in:
parent
8fb30b8ce4
commit
29dcccc6e4
@ -5609,10 +5609,15 @@ app.classes.mail = AppJS.extend(
|
|||||||
spamTitan_setActionTitle: function (_action, _sender)
|
spamTitan_setActionTitle: function (_action, _sender)
|
||||||
{
|
{
|
||||||
var id = _sender[0].id != 'nm'? _sender[0].id:_sender[1].id;
|
var id = _sender[0].id != 'nm'? _sender[0].id:_sender[1].id;
|
||||||
|
var email = this.egw.lang('emails');
|
||||||
|
var domain = this.egw.lang('domains');
|
||||||
var data = egw.dataGetUIDdata(id);
|
var data = egw.dataGetUIDdata(id);
|
||||||
var fromaddress = data.data.fromaddress.match(/<([^\'\" <>]+)>$/);
|
if(_sender.length === 1 && data && data.data && data.data.fromaddress)
|
||||||
var email = _sender.length>1? this.egw.lang('emails'):(fromaddress && fromaddress[1]) ?fromaddress[1]:data.data.fromaddress;
|
{
|
||||||
var domain = _sender.length>1? this.egw.lang('domains'):email.split('@')[1];
|
var fromaddress = data.data.fromaddress.match(/<([^\'\" <>]+)>$/);
|
||||||
|
email = (fromaddress && fromaddress[1]) ?fromaddress[1]:data.data.fromaddress;
|
||||||
|
domain = email.split('@')[1];
|
||||||
|
}
|
||||||
switch (_action.id)
|
switch (_action.id)
|
||||||
{
|
{
|
||||||
case 'whitelist_email_add':
|
case 'whitelist_email_add':
|
||||||
|
Loading…
Reference in New Issue
Block a user