Browse Source

ref(e2ee) change jsdoc return to correct promise

the editor will no longer complain about superfluous await when calling these functions
dev1
Jorge Oliveira 2 years ago
parent
commit
43ae27f990
1 changed files with 2 additions and 2 deletions
  1. 2
    2
      modules/e2ee/crypto-utils.js

+ 2
- 2
modules/e2ee/crypto-utils.js View File

30
  * Ratchets a key. See
30
  * Ratchets a key. See
31
  * https://tools.ietf.org/html/draft-omara-sframe-00#section-4.3.5.1
31
  * https://tools.ietf.org/html/draft-omara-sframe-00#section-4.3.5.1
32
  * @param {CryptoKey} material - base key material
32
  * @param {CryptoKey} material - base key material
33
- * @returns {ArrayBuffer} - ratcheted key material
33
+ * @returns {Promise<ArrayBuffer>} - ratcheted key material
34
  */
34
  */
35
 export async function ratchet(material) {
35
 export async function ratchet(material) {
36
     const textEncoder = new TextEncoder();
36
     const textEncoder = new TextEncoder();
49
  * suitable for our usage.
49
  * suitable for our usage.
50
  * @param {ArrayBuffer} keyBytes - raw key
50
  * @param {ArrayBuffer} keyBytes - raw key
51
  * @param {Array} keyUsages - key usages, see importKey documentation
51
  * @param {Array} keyUsages - key usages, see importKey documentation
52
- * @returns {CryptoKey} - the WebCrypto key.
52
+ * @returns {Promise<CryptoKey>} - the WebCrypto key.
53
  */
53
  */
54
 export async function importKey(keyBytes) {
54
 export async function importKey(keyBytes) {
55
     // https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/importKey
55
     // https://developer.mozilla.org/en-US/docs/Web/API/SubtleCrypto/importKey

Loading…
Cancel
Save