summaryrefslogtreecommitdiff
path: root/addons/web_linkedin/static/src/js
diff options
context:
space:
mode:
Diffstat (limited to 'addons/web_linkedin/static/src/js')
-rw-r--r--addons/web_linkedin/static/src/js/linkedin.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/addons/web_linkedin/static/src/js/linkedin.js b/addons/web_linkedin/static/src/js/linkedin.js
index b1e91b05810..013ad888cb9 100644
--- a/addons/web_linkedin/static/src/js/linkedin.js
+++ b/addons/web_linkedin/static/src/js/linkedin.js
@@ -118,14 +118,14 @@ openerp.web_linkedin = function(instance) {
pdef.resolve(result);
});
return $.when(cdef, pdef).then(function(companies, people) {
- var lst = companies.companies.values;
- var plst = people.people.values;
+ var lst = companies.companies.values || [];
+ var plst = people.people.values || [];
lst = _.initial(lst, _.min([self.limit / 2, plst.length]));
_.map(lst, function(el) {
el.__type = "company";
return el;
});
- plst = _.first(people.people.values, self.limit - lst.length)
+ plst = _.first(plst, self.limit - lst.length)
_.map(plst, function(el) {
el.__type = "people";
return el;