@@ -115,6 +115,7 @@ export interface ProvideCryptoSetupExtensions {
115
115
createSecretStorageKey ( ) : Uint8Array | null ;
116
116
catchAccessSecretStorageError ( e : Error ) : void ;
117
117
setupEncryptionNeeded : ( args : CryptoSetupArgs ) => boolean ;
118
+ /** @deprecated This callback is no longer used by matrix-react-sdk */
118
119
getDehydrationKeyCallback ( ) :
119
120
| ( ( keyInfo : SecretStorageKeyDescription , checkFunc : ( key : Uint8Array ) => void ) => Promise < Uint8Array > )
120
121
| null ;
@@ -128,9 +129,14 @@ export abstract class CryptoSetupExtensionsBase implements ProvideCryptoSetupExt
128
129
public abstract createSecretStorageKey ( ) : Uint8Array | null ;
129
130
public abstract catchAccessSecretStorageError ( e : Error ) : void ;
130
131
public abstract setupEncryptionNeeded ( args : CryptoSetupArgs ) : boolean ;
131
- public abstract getDehydrationKeyCallback ( ) :
132
+
133
+ /** `getDehydrationKeyCallback` is no longer used; we provide an empty impl for type compatibility. */
134
+ public getDehydrationKeyCallback ( ) :
132
135
| ( ( keyInfo : SecretStorageKeyDescription , checkFunc : ( key : Uint8Array ) => void ) => Promise < Uint8Array > )
133
- | null ;
136
+ | null {
137
+ return null ;
138
+ }
139
+
134
140
public abstract SHOW_ENCRYPTION_SETUP_UI : boolean ;
135
141
}
136
142
@@ -143,9 +149,8 @@ export interface CryptoSetupArgs {
143
149
/**
144
150
*
145
151
* The default/empty crypto-extensions
146
- * Can (and will) be used if none of the modules has an implementaion of IProvideCryptoSetupExtensions
147
- *
148
- * */
152
+ * Can (and will) be used if none of the modules has an implementation of {@link ProvideCryptoSetupExtensions}.
153
+ */
149
154
export class DefaultCryptoSetupExtensions extends CryptoSetupExtensionsBase {
150
155
public SHOW_ENCRYPTION_SETUP_UI = true ;
151
156
@@ -178,7 +183,6 @@ export class DefaultCryptoSetupExtensions extends CryptoSetupExtensionsBase {
178
183
public getDehydrationKeyCallback ( ) :
179
184
| ( ( keyInfo : SecretStorageKeyDescription , checkFunc : ( key : Uint8Array ) => void ) => Promise < Uint8Array > )
180
185
| null {
181
- console . log ( "Default empty getDehydrationKeyCallback() => null" ) ;
182
186
return null ;
183
187
}
184
188
}
0 commit comments