@@ -1333,7 +1333,7 @@ impl OlmMachine {
1333
1333
/// `callback` should be a function that takes a single argument (an array
1334
1334
/// of {@link RoomKeyInfo}) and returns a Promise.
1335
1335
#[ wasm_bindgen( js_name = "registerRoomKeyUpdatedCallback" ) ]
1336
- pub async fn register_room_key_updated_callback ( & self , callback : Function ) {
1336
+ pub fn register_room_key_updated_callback ( & self , callback : Function ) {
1337
1337
let stream = self . inner . store ( ) . room_keys_received_stream ( ) ;
1338
1338
1339
1339
copy_stream_to_callback (
@@ -1358,7 +1358,7 @@ impl OlmMachine {
1358
1358
/// `callback` should be a function that takes a single argument (an array
1359
1359
/// of {@link RoomKeyWithheldInfo}) and returns a Promise.
1360
1360
#[ wasm_bindgen( js_name = "registerRoomKeysWithheldCallback" ) ]
1361
- pub async fn register_room_keys_withheld_callback ( & self , callback : Function ) {
1361
+ pub fn register_room_keys_withheld_callback ( & self , callback : Function ) {
1362
1362
let stream = self . inner . store ( ) . room_keys_withheld_received_stream ( ) ;
1363
1363
1364
1364
copy_stream_to_callback (
@@ -1383,7 +1383,7 @@ impl OlmMachine {
1383
1383
/// `callback` should be a function that takes a single argument (a {@link
1384
1384
/// UserId}) and returns a Promise.
1385
1385
#[ wasm_bindgen( js_name = "registerUserIdentityUpdatedCallback" ) ]
1386
- pub async fn register_user_identity_updated_callback ( & self , callback : Function ) {
1386
+ pub fn register_user_identity_updated_callback ( & self , callback : Function ) {
1387
1387
let stream = self . inner . store ( ) . identities_stream_raw ( ) ;
1388
1388
1389
1389
copy_stream_to_callback (
@@ -1406,7 +1406,7 @@ impl OlmMachine {
1406
1406
/// `callback` should be a function that takes a single argument (an array
1407
1407
/// of user IDs as strings) and returns a Promise.
1408
1408
#[ wasm_bindgen( js_name = "registerDevicesUpdatedCallback" ) ]
1409
- pub async fn register_devices_updated_callback ( & self , callback : Function ) {
1409
+ pub fn register_devices_updated_callback ( & self , callback : Function ) {
1410
1410
let stream = self . inner . store ( ) . identities_stream_raw ( ) ;
1411
1411
1412
1412
fn mapper ( changes : ( IdentityChanges , DeviceChanges ) ) -> iter:: Once < Array > {
@@ -1454,7 +1454,7 @@ impl OlmMachine {
1454
1454
/// secret inbox should be cleared by calling
1455
1455
/// `delete_secrets_from_inbox`.
1456
1456
#[ wasm_bindgen( js_name = "registerReceiveSecretCallback" ) ]
1457
- pub async fn register_receive_secret_callback ( & self , callback : Function ) {
1457
+ pub fn register_receive_secret_callback ( & self , callback : Function ) {
1458
1458
let stream = self . inner . store ( ) . secrets_stream ( ) ;
1459
1459
// fire up a promise chain which will call `callback` on each result from the
1460
1460
// stream
@@ -1487,7 +1487,7 @@ impl OlmMachine {
1487
1487
/// If the secret is valid and handled, the secret inbox should be cleared
1488
1488
/// by calling `delete_secrets_from_inbox`.
1489
1489
#[ wasm_bindgen( js_name = "getSecretsFromInbox" ) ]
1490
- pub async fn get_secrets_from_inbox ( & self , secret_name : String ) -> Promise {
1490
+ pub fn get_secrets_from_inbox ( & self , secret_name : String ) -> Promise {
1491
1491
let set = Set :: new ( & JsValue :: UNDEFINED ) ;
1492
1492
let me = self . inner . clone ( ) ;
1493
1493
@@ -1509,7 +1509,7 @@ impl OlmMachine {
1509
1509
///
1510
1510
/// * `secret_name` - The name of the secret to delete.
1511
1511
#[ wasm_bindgen( js_name = "deleteSecretsFromInbox" ) ]
1512
- pub async fn delete_secrets_from_inbox ( & self , secret_name : String ) -> Promise {
1512
+ pub fn delete_secrets_from_inbox ( & self , secret_name : String ) -> Promise {
1513
1513
let me = self . inner . clone ( ) ;
1514
1514
future_to_promise ( async move {
1515
1515
let name = SecretName :: from ( secret_name) ;
@@ -1534,7 +1534,7 @@ impl OlmMachine {
1534
1534
/// A `Promise` for a `bool` result, which will be true if secrets were
1535
1535
/// missing, and a request was generated.
1536
1536
#[ wasm_bindgen( js_name = "requestMissingSecretsIfNeeded" ) ]
1537
- pub async fn request_missing_secrets_if_needed ( & self ) -> Promise {
1537
+ pub fn request_missing_secrets_if_needed ( & self ) -> Promise {
1538
1538
let me = self . inner . clone ( ) ;
1539
1539
future_to_promise ( async move {
1540
1540
let has_missing_secrets = me. query_missing_secrets_from_other_sessions ( ) . await ?;
0 commit comments