Skip to content

Commit

Permalink
fix(conditions): fix passing context to sync list relations
Browse files Browse the repository at this point in the history
  • Loading branch information
rhamzeh committed Jan 9, 2024
1 parent f0b8d57 commit af0082c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions openfga_sdk/sync/client/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -633,8 +633,8 @@ def list_relations(self, body: ClientListRelationsRequest, options: dict[str, st
options = set_heading_if_not_set(options, CLIENT_METHOD_HEADER, "ListRelations")
options = set_heading_if_not_set(options, CLIENT_BULK_REQUEST_ID_HEADER, str(uuid.uuid4()))

request_body = [construct_check_request(
user=body.user, relation=i, object=body.object, contextual_tuples=body.contextual_tuples) for i in body.relations]
request_body = [construct_check_request(user=body.user, relation=i, object=body.object,
contextual_tuples=body.contextual_tuples, context=body.context) for i in body.relations]
result = self.batch_check(request_body, options)
# need to filter with the allowed response
result_iterator = filter(_check_allowed, result)
Expand Down

0 comments on commit af0082c

Please sign in to comment.