Skip to content

Commit

Permalink
[FIX] - row level auth and invitations hybrid property (#2756)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jsyro authored Oct 26, 2023
1 parent d7e5daf commit 363cf43
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 1 addition & 2 deletions services/core-api/app/api/parties/party/models/party.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,8 +115,7 @@ def business_roles_codes(self):

@hybrid_property
def digital_wallet_connection_status(self):
current_app.logger.warning(self.digital_wallet_invitations)
dwi = [i for i in self.digital_wallet_invitations if i.connection_status] # filter empty conn_state
dwi = [i for i in self.digital_wallet_invitations if i.connection_state] # filter empty conn_state
if dwi:
current_app.logger.warning(dwi)
return dwi.connection_state # active >> invitation
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import enum
from flask import current_app, request
from flask_restplus import Resource
from app.api.utils.include.user_info import User

from app.extensions import api

Expand All @@ -18,6 +19,7 @@
class VerifiableCredentialWebhookResource(Resource, UserMixin):
@api.doc(description='Endpoint to recieve webhooks from Traction.', params={})
def post(self, topic):
User._test_mode = True #webhook handling has no row level auth
webhook_body = request.get_json()
current_app.logger.warning(f"TRACTION WEBHOOK <topic={topic}>: {webhook_body}")
if topic == CONNECTIONS:
Expand Down

0 comments on commit 363cf43

Please sign in to comment.