mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-25 01:13:25 +01:00
Avoid JS error if value is undefined
This commit is contained in:
parent
dcc553bc23
commit
23625effb7
@ -183,7 +183,7 @@ var et2_link_to = (function(){ "use strict"; return et2_inputWidget.extend(
|
||||
};
|
||||
// only set server-side callback, if we have a real application-id (not null or array)
|
||||
// otherwise it only gives an error on server-side
|
||||
if (self.options.value.to_id && typeof self.options.value.to_id != 'object') {
|
||||
if (self.options.value && self.options.value.to_id && typeof self.options.value.to_id != 'object') {
|
||||
select_attrs.method = 'EGroupware\\Api\\Etemplate\\Widget\\Link::link_existing';
|
||||
select_attrs.method_id = self.options.value.to_app + ':' + self.options.value.to_id;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user