gotgcalls-server
Advanced tools
Comparing version 0.0.0-rc.6 to 0.0.0-rc.7
@@ -29,8 +29,16 @@ "use strict"; | ||
const tgcalls = new base_tgcalls_1.BaseTGCalls(null); | ||
tgcalls.joinVoiceCall = async (payload) => JSON.parse(await this.connection.dispatch("joinCall", { | ||
chatId, | ||
isChat, | ||
accessHash, | ||
payload, | ||
})); | ||
tgcalls.joinVoiceCall = async (payload) => { | ||
try { | ||
return JSON.parse(await this.connection.dispatch("joinCall", { | ||
chatId, | ||
isChat, | ||
accessHash, | ||
payload, | ||
})); | ||
} | ||
catch (err) { | ||
this.stop(chatId); | ||
throw err; | ||
} | ||
}; | ||
const stream = new base_tgcalls_1.Stream(readable); | ||
@@ -37,0 +45,0 @@ stream.on("finish", () => { |
{ | ||
"name": "gotgcalls-server", | ||
"version": "0.0.0-rc.6", | ||
"version": "0.0.0-rc.7", | ||
"main": "dist/index.js", | ||
@@ -5,0 +5,0 @@ "bin": "dist/index.js", |
@@ -31,11 +31,17 @@ import { createReadStream } from "fs"; | ||
const tgcalls = new BaseTGCalls(null); | ||
tgcalls.joinVoiceCall = async (payload) => | ||
JSON.parse( | ||
await this.connection.dispatch("joinCall", { | ||
chatId, | ||
isChat, | ||
accessHash, | ||
payload, | ||
}), | ||
); | ||
tgcalls.joinVoiceCall = async (payload) => { | ||
try { | ||
return JSON.parse( | ||
await this.connection.dispatch("joinCall", { | ||
chatId, | ||
isChat, | ||
accessHash, | ||
payload, | ||
}), | ||
); | ||
} catch (err) { | ||
this.stop(chatId); | ||
throw err; | ||
} | ||
}; | ||
const stream = new Stream(readable); | ||
@@ -42,0 +48,0 @@ stream.on("finish", () => { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
22741
485