You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 1, 2021. It is now read-only.
Currently using firebase's node js cloud servers and want to download images of documents to my own storage to later show user. Yet when I try to download the image from onfido js-client I get an error saying "File is not defined". Any idea why? I am new to node.js and backend should I be parsing the return object to a certain type of file ??
The text was updated successfully, but these errors were encountered:
Hi! could you please contact the Onfido support team at [email protected]?
Could you also please give us more details on how you are downloading the documents? (i.e. the request that you sent to the Onfido API)
Best regards
ReferenceError: File is not defined
at exports.downloadDocumentWithHttpInfo (/private/var/www/onfido-backuper/node_modules/onfido/src/api/DefaultApi.js:406:24)
at exports.downloadDocument (/private/var/www/onfido-backuper/node_modules/onfido/src/api/DefaultApi.js:422:19)
...
In DefaultApi.js you can see:
var authNames = ['Token'];
var contentTypes = [];
var accepts = ['*/*', 'application/json'];
var returnType = File; // <------------ there an unknown variable is referenced
return this.apiClient.callApi(
'/applicants/{applicant_id}/documents/{document_id}/download', 'GET',
pathParams, queryParams, collectionQueryParams, headerParams, formParams, postBody,
authNames, contentTypes, accepts, returnType
);
When using var returnType = 'Blob'; it works as it should.
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Currently using firebase's node js cloud servers and want to download images of documents to my own storage to later show user. Yet when I try to download the image from onfido js-client I get an error saying "File is not defined". Any idea why? I am new to node.js and backend should I be parsing the return object to a certain type of file ??
The text was updated successfully, but these errors were encountered: