[FIX] hr_holidays: Add missing context check

Fixes #4341
This commit is contained in:
Yannick Vaucher 2014-12-19 10:53:25 +01:00 committed by Martin Trigaux
parent 26bf35260d
commit ead3f039df
1 changed files with 2 additions and 1 deletions

View File

@ -90,7 +90,8 @@ class hr_holidays_status(osv.osv):
}
def name_get(self, cr, uid, ids, context=None):
if context is None:
context = {}
if not context.get('employee_id',False):
# leave counts is based on employee_id, would be inaccurate if not based on correct employee
return super(hr_holidays_status, self).name_get(cr, uid, ids, context=context)