mirror of
https://github.com/owncloudarchive/contacts.git
synced 2025-01-30 19:52:17 +01:00
Check if 'data' is set before acessing it's properties. Refs #373
This commit is contained in:
parent
c3d30be656
commit
11bdcb2810
@ -95,7 +95,7 @@ OC.Contacts = OC.Contacts || {};
|
||||
};
|
||||
|
||||
Contact.prototype.hasPhoto = function() {
|
||||
return this.data.photo;
|
||||
return (this.data && this.data.photo) || false;
|
||||
};
|
||||
|
||||
Contact.prototype.isOpen = function() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user