import { BlockPersonResponse, MyUserInfo } from "lemmy-js-client";
-import { i18n } from "../../i18next";
-import { UserService } from "../../services";
+import { I18NextService, UserService } from "../../services";
import { toast } from "../../toast";
export default function updatePersonBlock(
person: myUserInfo.local_user_view.person,
target: data.person_view.person,
});
- toast(`${i18n.t("blocked")} ${data.person_view.person.name}`);
+ toast(
+ `${I18NextService.i18n.t("blocked")} ${data.person_view.person.name}`
+ );
} else {
myUserInfo.person_blocks = myUserInfo.person_blocks.filter(
i => i.target.id !== data.person_view.person.id
);
- toast(`${i18n.t("unblocked")} ${data.person_view.person.name}`);
+ toast(
+ `${I18NextService.i18n.t("unblocked")} ${data.person_view.person.name}`
+ );
}
}
}