Skip to content

Commit

Permalink
added set_cookies method
Browse files Browse the repository at this point in the history
  • Loading branch information
DinisCruz committed Oct 29, 2024
1 parent 1ef84c9 commit 1d6bbe5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions osbot_fast_api/utils/Fast_API__Request.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@ def set_cookie(self, key, value):
self.set_header('cookie', f'{key}={value}')
return self

def set_cookies(self, items):
for key, value in items:
self.set_header('cookie', f'{key}={value}')
return self

def set_header(self, key, value):
self.scope_headers[key] = value
return self
Expand Down

0 comments on commit 1d6bbe5

Please sign in to comment.