mirror of
https://github.com/Nezumi-2711/google-drive-s3.git
synced 2026-09-22 13:38:30 +00:00
fix: add modified value for object
This commit is contained in:
+3
-1
@@ -11,7 +11,7 @@ interface GoogleDriveCreateResponse {
|
||||
id: string;
|
||||
}
|
||||
|
||||
const DRIVE_FIELDS = "id,name,size,mimeType,md5Checksum";
|
||||
const DRIVE_FIELDS = "id,name,size,mimeType,md5Checksum,modifiedTime";
|
||||
const FOLDER_MIME_TYPE = "application/vnd.google-apps.folder";
|
||||
const LIST_NODE_CAP = 5000;
|
||||
|
||||
@@ -227,6 +227,7 @@ export async function streamDownloadFromDrive(accessToken: string, bucket: strin
|
||||
size: parseInt(file.size || "0", 10),
|
||||
id: file.id,
|
||||
md5Checksum: file.md5Checksum,
|
||||
modifiedTime: file.modifiedTime,
|
||||
status: downloadRes.status,
|
||||
contentRange: downloadRes.headers.get("Content-Range") ?? undefined,
|
||||
contentLength: downloadRes.headers.get("Content-Length") ?? undefined,
|
||||
@@ -264,6 +265,7 @@ export async function getFileMetadata(accessToken: string, bucket: string, objec
|
||||
mimeType: file.mimeType || "application/octet-stream",
|
||||
size: parseInt(file.size || "0", 10),
|
||||
md5Checksum: file.md5Checksum,
|
||||
modifiedTime: file.modifiedTime,
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user