Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/gram-js/gramjs
Browse files Browse the repository at this point in the history
  • Loading branch information
painor committed Aug 24, 2024
2 parents b0d317c + 7db1921 commit 372ee41
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion gramjs/client/downloads.ts
Original file line number Diff line number Diff line change
Expand Up @@ -430,13 +430,13 @@ export async function downloadFileV2(
msgData: msgData,
})) {
await writer.write(chunk);
downloaded = downloaded.add(chunk.length);
if (progressCallback) {
await progressCallback(
downloaded,
bigInt(fileSize || bigInt.zero)
);
}
downloaded = downloaded.add(chunk.length);
}
return returnWriterValue(writer);
} finally {
Expand Down
4 changes: 2 additions & 2 deletions gramjs/define.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ type OutFile =
| WriteStream
| { write: Function; close?: Function };
type ProgressCallback = (
total: bigInt.BigInteger,
downloaded: bigInt.BigInteger
downloaded: bigInt.BigInteger,
total: bigInt.BigInteger
) => void;
type ButtonLike = Api.TypeKeyboardButton | Button;

Expand Down

0 comments on commit 372ee41

Please sign in to comment.