Skip to content

Commit

Permalink
fix: get access token (#602)
Browse files Browse the repository at this point in the history
* fix: get access token

* Fix

* Fix

---------

Co-authored-by: GitHub Actions <[email protected]>
  • Loading branch information
ruuushhh and GitHub Actions committed Jan 31, 2025
1 parent 85c0f96 commit 9d87684
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion apps/fyle/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ def post_request(url: str, body: dict, refresh_token: str = None) -> Optional[di
response = requests.post(
url,
headers=api_headers,
data=body
data=json.dumps(body)
)

if response.status_code in [200, 201]:
Expand Down
3 changes: 1 addition & 2 deletions apps/workspaces/tasks.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import json
import logging
from datetime import datetime, timedelta, date

Expand Down Expand Up @@ -241,7 +240,7 @@ def post_to_integration_settings(workspace_id: int, active: bool) -> None:
}

try:
post_request(url, json.dumps(payload), refresh_token)
post_request(url, payload, refresh_token)
except Exception as error:
logger.error(error)

Expand Down

0 comments on commit 9d87684

Please sign in to comment.