From 091b277f7df5eb78233099cec2c1c5224dafde69 Mon Sep 17 00:00:00 2001 From: "M.Ravi" Date: Tue, 12 Dec 2017 12:42:40 +0100 Subject: [PATCH] Correct call to has_perm --- hosting/views.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/hosting/views.py b/hosting/views.py index c04bcf30..68f55433 100644 --- a/hosting/views.py +++ b/hosting/views.py @@ -687,7 +687,9 @@ class OrdersHostingDetailView(LoginRequiredMixin, order_id=order_id )) hosting_order_obj = None - if not self.request.user.has_perm(hosting_order_obj): + if not self.request.user.has_perm( + self.permission_required[0], hosting_order_obj + ): logger.debug( "User {user} does not have permission on HostingOrder " "{order_id}. Raising 404 error now.".format(