@@ -124,10 +124,10 @@ export const ClientProvider: FC<Props> = ({ children }) => {
|
||||
|
||||
const onSync = (state: SyncState, _old: SyncState, data: ISyncStateData) => {
|
||||
setState((currentState) => {
|
||||
return {
|
||||
...currentState,
|
||||
disconnected: isDisconnected(state, data),
|
||||
};
|
||||
const disconnected = isDisconnected(state, data);
|
||||
return disconnected === currentState.disconnected
|
||||
? currentState
|
||||
: { ...currentState, disconnected };
|
||||
});
|
||||
};
|
||||
|
||||
@@ -205,7 +205,7 @@ export const ClientProvider: FC<Props> = ({ children }) => {
|
||||
}
|
||||
}
|
||||
};
|
||||
let clientWithListener;
|
||||
let clientWithListener: MatrixClient;
|
||||
init()
|
||||
.then(({ client, isPasswordlessUser }) => {
|
||||
clientWithListener = client;
|
||||
|
||||
@@ -23,5 +23,5 @@ limitations under the License.
|
||||
text-align: center;
|
||||
z-index: 1;
|
||||
top: 76px;
|
||||
width: 100%;
|
||||
width: calc(100% - 58px);
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ export class Initializer {
|
||||
private isInitialized = false;
|
||||
|
||||
public static isInitialized(): boolean {
|
||||
return Boolean(Initializer.internalInstance?.isInitialized);
|
||||
return Initializer.internalInstance?.isInitialized;
|
||||
}
|
||||
|
||||
public static initBeforeReact() {
|
||||
|
||||
Reference in New Issue
Block a user