Skip to content

Commit

Permalink
Made methods consistent
Browse files Browse the repository at this point in the history
  • Loading branch information
hassansuhaib committed Sep 18, 2023
1 parent a664f01 commit ade429a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/driver-azure/src/driver/fs/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,19 @@ export const azureStorageBlobFs = async (azureBlobUrl: string): Promise<VirtualF
await ensureBucketExists(blobServiceClient, containerName)

return {
async read(filename: string) {
read: async (filename: string) => {
const blobClient = containerClient.getBlobClient(filename)
const result = await blobClient.download()
if (result.readableStreamBody !== undefined) {
return await streamToBuffer(result.readableStreamBody)
}
return undefined
},
async write(filename: string, content: Buffer | string) {
write: async (filename: string, content: Buffer | string) => {
const blockBlobClient = containerClient.getBlockBlobClient(filename)
await blockBlobClient.upload(content, content.length)
},
async delete(filename: string) {
delete: async (filename: string) => {
const blockBlobClient = containerClient.getBlockBlobClient(filename)
const options: BlobDeleteOptions = {
deleteSnapshots: 'include',
Expand Down

0 comments on commit ade429a

Please sign in to comment.