Skip to content

Commit

Permalink
fix: invalid export
Browse files Browse the repository at this point in the history
  • Loading branch information
drochetti committed Nov 2, 2023
1 parent 3dc2665 commit 698b95a
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
1 change: 0 additions & 1 deletion libs/client/src/index.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
export { config, getConfig } from './config';
export { storageImpl as storage } from './storage';
export type { UploadOptions } from './storage';
export { queue, run, subscribe } from './function';
export { withMiddleware, withProxy } from './middleware';
export type { RequestMiddleware } from './middleware';
Expand Down
8 changes: 5 additions & 3 deletions libs/client/src/storage.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import { getConfig } from './config';
import { dispatchRequest } from './request';


/**
* File support for the client. This interface establishes the contract for
* uploading files to the server and transforming the input to replace file
Expand Down Expand Up @@ -55,7 +54,10 @@ async function initiateUpload(file: Blob): Promise<InitiateUploadResult> {
return await dispatchRequest<InitiateUploadData, InitiateUploadResult>(
'POST',
'https://rest.daniel.shark.fal.ai/storage/upload/initiate',
{ file_name: file.name, content_type: file.type || 'application/octet-stream' }
{
file_name: file.name,
content_type: file.type || 'application/octet-stream',
}
);
}

Expand All @@ -70,7 +72,7 @@ export const storageImpl: StorageSupport = {
body: file,
headers: {
'Content-Type': file.type || 'application/octet-stream',
}
},
});
const { responseHandler } = getConfig();
await responseHandler(response);
Expand Down

0 comments on commit 698b95a

Please sign in to comment.