Skip to content

Commit

Permalink
[FIX] subscription_oca : Fix for issue when uid is not found in context
Browse files Browse the repository at this point in the history
  • Loading branch information
ByteMeAsap committed Feb 13, 2025
1 parent f1e0aae commit 05a993e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion subscription_oca/models/sale_order.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ def create_subscription(self, lines, subscription_tmpl):
rec = self.env["sale.subscription"].create(
{
"partner_id": self.partner_id.id,
"user_id": self._context["uid"],
"user_id": self._context.get("uid", False),
"template_id": subscription_tmpl.id,
"pricelist_id": self.partner_id.property_product_pricelist.id,
"date_start": date.today(),
Expand Down

0 comments on commit 05a993e

Please sign in to comment.