fix(infra): reduce workspace avatar request (#6713)

This commit is contained in:
EYHN
2024-04-28 07:06:27 +00:00
parent 7584ab4b91
commit 236c6e00df

View File

@@ -1,5 +1,5 @@
import { DebugLogger } from '@affine/debug';
import { catchError, EMPTY, mergeMap, switchMap } from 'rxjs';
import { catchError, EMPTY, exhaustMap, mergeMap } from 'rxjs';
import { Entity } from '../../../framework';
import {
@@ -59,7 +59,7 @@ export class WorkspaceProfile extends Entity<{ metadata: WorkspaceMetadata }> {
}
revalidate = effect(
switchMap(() => {
exhaustMap(() => {
const provider = this.provider;
if (!provider) {
return EMPTY;