mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-09 07:28:43 +01:00
fixing TypeError stoping etemplate.test.contact_widget from displaying, because attribute "type" is not defined
maybe we dont want setting of undefined attributes, but then it should give a clear error (eg. exception) --> https://localhost/egroupware/etemplate/inc/class.etemplate_new.inc.php?name=etemplate.test.contact_widget tests contact-widgets
This commit is contained in:
parent
502ac42923
commit
fb62831e86
@ -477,7 +477,7 @@
|
||||
Class.prototype.initAttributes = function(_attrs) {
|
||||
for (var key in _attrs)
|
||||
{
|
||||
if (!this.attributes[key].ignore && !(_attrs[key] == undefined))
|
||||
if (typeof this.attributes[key] != "undefined" && !this.attributes[key].ignore && !(_attrs[key] == undefined))
|
||||
{
|
||||
this.setAttribute(key, _attrs[key], false);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user