mirror of
https://github.com/vector-im/hydrogen-web.git
synced 2024-12-23 19:45:05 +01:00
don't automatically join a call we create
This commit is contained in:
parent
b84c90891c
commit
9be64730b6
@ -359,7 +359,8 @@ export class RoomViewModel extends ViewModel {
|
|||||||
const mediaTracks = await this.platform.mediaDevices.getMediaTracks(false, true);
|
const mediaTracks = await this.platform.mediaDevices.getMediaTracks(false, true);
|
||||||
const localMedia = new LocalMedia().withTracks(mediaTracks);
|
const localMedia = new LocalMedia().withTracks(mediaTracks);
|
||||||
// this will set the callViewModel above as a call will be added to callHandler.calls
|
// this will set the callViewModel above as a call will be added to callHandler.calls
|
||||||
await session.callHandler.createCall(this._room.id, localMedia, "A call " + Math.round(this.platform.random() * 100));
|
const call = await session.callHandler.createCall(this._room.id, localMedia, "A call " + Math.round(this.platform.random() * 100));
|
||||||
|
await call.join(localMedia);
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
console.error(err.stack);
|
console.error(err.stack);
|
||||||
alert(err.message);
|
alert(err.message);
|
||||||
|
@ -117,7 +117,6 @@ export class CallHandler {
|
|||||||
|
|
||||||
try {
|
try {
|
||||||
await call.create(localMedia);
|
await call.create(localMedia);
|
||||||
await call.join(localMedia);
|
|
||||||
// store call info so it will ring again when reopening the app
|
// store call info so it will ring again when reopening the app
|
||||||
const txn = await this.options.storage.readWriteTxn([this.options.storage.storeNames.calls]);
|
const txn = await this.options.storage.readWriteTxn([this.options.storage.storeNames.calls]);
|
||||||
txn.calls.add({
|
txn.calls.add({
|
||||||
|
Loading…
Reference in New Issue
Block a user