Don't call familiar_followers if not same instance as logged-in instance

This commit is contained in:
Lim Chee Aun 2023-09-23 22:38:29 +08:00
parent 4c3666df6a
commit 7ba5ee5fe2

View file

@ -73,6 +73,11 @@ function AccountInfo({
[account?.id],
);
const sameCurrentInstance = useMemo(
() => instance === api().instance,
[instance],
);
useEffect(() => {
if (!isString) {
setInfo(account);
@ -141,6 +146,7 @@ function AccountInfo({
}
const results = await followersIterator.current.next();
if (isSelf) return results;
if (!sameCurrentInstance) return results;
const { value } = results;
let newValue = [];