fix: NO_LIMIT_SEND_ROLE when user settings not call (#396)

This commit is contained in:
Dream Hunter
2024-08-11 23:45:24 +08:00
committed by GitHub
parent c6d0307eac
commit 7e5d142924
5 changed files with 13 additions and 4 deletions

View File

@@ -13,7 +13,7 @@ const isPreview = ref(false)
const editorRef = shallowRef()
const { settings, sendMailModel, indexTab } = useGlobalState()
const { settings, sendMailModel, indexTab, userSettings } = useGlobalState()
const { t } = useI18n({
locale: 'zh',
@@ -136,6 +136,8 @@ const handleCreated = (editor) => {
}
onMounted(async () => {
// make sure user_id is fetched
if (!userSettings.value.user_id) await api.getUserSettings(message);
await api.getSettings();
})
</script>