Skip to content

Commit

Permalink
[FIX]hr_holidays_public: mute distracting warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
PicchiSeba committed Feb 4, 2025
1 parent 4bc5f0c commit e5db3d2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion hr_holidays_public/models/hr_holidays_public.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,11 @@ def get_holidays_list(
:param employee_id: ID of the employee
:return: recordset of hr.holidays.public.line
"""
partner = self._get_partner_deprecated_employee(partner_id, employee_id)
partner = (
self.env["hr.employee"].browse(employee_id).address_id
if employee_id and not partner_id
else self._get_partner_deprecated_employee(partner_id, employee_id)
)
if not start_dt and not end_dt:
start_dt = datetime.date(year, 1, 1)
end_dt = datetime.date(year, 12, 31)
Expand Down

0 comments on commit e5db3d2

Please sign in to comment.