Skip to content

Commit 0696d7c

Browse files
committed
Fix for Python 2.7 compatibility
1 parent 5f11114 commit 0696d7c

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

ravenpackapi/upload/models.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -158,9 +158,10 @@ def save(self):
158158

159159
@api_method
160160
def text_extraction(self, output_format="text/csv"):
161+
headers = self.api.headers.copy()
162+
headers["Content-type"] = output_format
161163
response = self.api.request('%s/files/%s/text-extraction' % (self.api._UPLOAD_BASE_URL, self.file_id),
162-
headers={**self.api.headers,
163-
"Content-type": output_format},
164+
headers=headers,
164165
)
165166
return response.text
166167

0 commit comments

Comments
 (0)