Fix stream not correctly closed on dispose

This commit is contained in:
Ming Ming 2023-07-22 22:24:14 +08:00
parent 484da170d4
commit 512e67d569
2 changed files with 7 additions and 2 deletions

View file

@ -12,7 +12,10 @@ class AccountPrefController {
required this.account,
}) : _accountPref = AccountPref.of(account);
void dispose() {}
void dispose() {
_shareFolderController.close();
_accountLabelController.close();
}
ValueStream<bool> get isEnableFaceRecognitionApp =>
_enableFaceRecognitionAppController.stream;

View file

@ -21,7 +21,9 @@ class ServerController {
required this.account,
});
void dispose() {}
void dispose() {
_statusStreamContorller.close();
}
ValueStream<ServerStatus> get status {
if (!_statusStreamContorller.hasValue) {