Skip to content

Commit e15ccad

Browse files
authored
Google Drive: Download File action bug fix (#17055)
* update workspace-export-formats * pnpm-lock.yaml * pnpm-lock.yaml * pnpm-lock.yaml * file structure
1 parent 5a605a0 commit e15ccad

File tree

3 files changed

+31
-4
lines changed

3 files changed

+31
-4
lines changed

components/google_drive/actions/google-workspace-export-formats.mjs renamed to components/google_drive/actions/common/google-workspace-export-formats.mjs

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,22 @@ export default [
3939
value: "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
4040
label: "MS Word document",
4141
},
42+
{
43+
value: "application/vnd.oasis.opendocument.text",
44+
label: "OpenDocument Text",
45+
},
46+
{
47+
value: "application/vnd.oasis.opendocument.spreadsheet",
48+
label: "OpenDocument Spreadsheet",
49+
},
50+
{
51+
value: "application/vnd.oasis.opendocument.presentation",
52+
label: "OpenDocument Presentation",
53+
},
54+
{
55+
value: "application/vnd.google-apps.vid",
56+
label: "MP4",
57+
},
4258
{
4359
value: "application/zip",
4460
label: "HTML (zipped)",
@@ -71,4 +87,12 @@ export default [
7187
value: "text/tab-separated-values",
7288
label: "TSV (sheet only)",
7389
},
90+
{
91+
value: "text/markdown",
92+
label: "Markdown",
93+
},
94+
{
95+
value: "text/x-markdown",
96+
label: "Markdown (Deprecated)",
97+
},
7498
];

components/google_drive/actions/download-file/download-file.mjs

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import fs from "fs";
33
import stream from "stream";
44
import { promisify } from "util";
55
import { GOOGLE_DRIVE_MIME_TYPE_PREFIX } from "../../common/constants.mjs";
6-
import googleWorkspaceExportFormats from "../google-workspace-export-formats.mjs";
6+
import googleWorkspaceExportFormats from "../common/google-workspace-export-formats.mjs";
77
import { toSingleLineString } from "../../common/utils.mjs";
88

99
/**
@@ -18,7 +18,7 @@ export default {
1818
key: "google_drive-download-file",
1919
name: "Download File",
2020
description: "Download a file. [See the documentation](https://developers.google.com/drive/api/v3/manage-downloads) for more information",
21-
version: "0.1.9",
21+
version: "0.1.10",
2222
type: "action",
2323
props: {
2424
googleDrive,
@@ -82,7 +82,10 @@ export default {
8282
return exportFormats[file.mimeType].map((f) =>
8383
googleWorkspaceExportFormats.find(
8484
(format) => format.value === f,
85-
) ?? f);
85+
) ?? {
86+
value: f,
87+
label: f,
88+
});
8689
},
8790
},
8891
},

components/google_drive/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@pipedream/google_drive",
3-
"version": "0.10.0",
3+
"version": "0.10.1",
44
"description": "Pipedream Google_drive Components",
55
"main": "google_drive.app.mjs",
66
"keywords": [

0 commit comments

Comments
 (0)