Skip to content

Commit

Permalink
Fix X-Last-Seen-Txn header (#250)
Browse files Browse the repository at this point in the history
The incorrect header is set on non-streaming queries. Instead of X-Last-Txn-Time, set X-Last-Seen-Txn.
  • Loading branch information
pnwpedro authored Oct 12, 2022
1 parent 17f8021 commit c644bb8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions faunadb/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -111,12 +111,12 @@ def time(self):

@property
def request_header(self):
"""Produces a dictionary with a non-zero `X-Last-Txn-Time` header; or,
"""Produces a dictionary with a non-zero `X-Last-Seen-Txn` header; or,
if one has not yet been set, the empty header dictionary."""
t = self.time
if t is None:
return {}
return {"X-Last-Txn-Time": str(t)}
return {"X-Last-Seen-Txn": str(t)}

def update_txn_time(self, new_txn_time):
"""Updates the internal transaction time.
Expand Down

0 comments on commit c644bb8

Please sign in to comment.