If first addressbook was empty it was seen as if there where no contacts at all.
This commit is contained in:
parent
a1239a37aa
commit
a484ee817c
|
@ -316,8 +316,11 @@ OC.Contacts={
|
|||
console.log('Card, cid: ' + params.cid + ' aid: ' + params.aid);
|
||||
var newid, bookid, firstitem;
|
||||
if(!parseInt(params.cid) && !parseInt(params.aid)) {
|
||||
firstitem = $('#contacts ul').first().find('li:first-child');
|
||||
firstitem = $('#contacts ul').find('li:first-child');
|
||||
if(firstitem.length > 0) {
|
||||
if(firstitem.length > 1) {
|
||||
firstitem = firstitem.first();
|
||||
}
|
||||
newid = parseInt(firstitem.data('id'));
|
||||
bookid = parseInt(firstitem.data('bookid'));
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue