feat: update proto

The new proto extract has a bunch of breaking changes, so if you were using the raw proto in your code somewhere -- then you may have to update your code to make it work with the new proto

!BREAKING_CHANGE
This commit is contained in:
Adhiraj Singh
2022-08-01 10:43:01 +05:30
parent 9c83cd96d2
commit 2549d10be9
22 changed files with 58772 additions and 55399 deletions

View File

@@ -550,8 +550,8 @@ export const makeMessagesSocket = (config: SocketConfig) => {
} else {
try {
const media = decryptMediaRetryData(result.media!, mediaKey, result.key.id!)
if(media.result !== proto.MediaRetryNotification.MediaRetryNotificationResultType.SUCCESS) {
const resultStr = proto.MediaRetryNotification.MediaRetryNotificationResultType[media.result]
if(media.result !== proto.MediaRetryNotification.ResultType.SUCCESS) {
const resultStr = proto.MediaRetryNotification.ResultType[media.result]
throw new Boom(
`Media re-upload failed by device (${resultStr})`,
{ data: media, statusCode: getStatusCodeForMediaRetry(media.result) || 404 }