Bläddra i källkod

add outputFile to DownloadProfilePhotoParams (#361)

SecurityAndStuff 3 år sedan
förälder
incheckning
18be5ebf55
1 ändrade filer med 2 tillägg och 0 borttagningar
  1. 2 0
      gramjs/client/downloads.ts

+ 2 - 0
gramjs/client/downloads.ts

@@ -85,6 +85,7 @@ export interface DownloadFileParamsV2 {
 export interface DownloadProfilePhotoParams {
     /** Whether to download the big version or the small one of the photo */
     isBig?: boolean;
+    outputFile?: OutFile;
 }
 
 interface Deferred {
@@ -854,6 +855,7 @@ export async function downloadProfilePhoto(
         return Buffer.alloc(0);
     }
     return client.downloadFile(loc, {
+        outputFile: fileParams.outputFile,
         dcId,
     });
 }