From da7cc78a7eacb841432e266ab9d3f9b6a94838c4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joaqu=C3=ADn=20S=C3=A1nchez?= Date: Sun, 12 Feb 2023 16:15:29 +0100 Subject: [PATCH] fix: revert #1699 (#1730) --- components/publish/PublishWidget.vue | 4 +--- composables/masto/statusDrafts.ts | 4 ++-- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/components/publish/PublishWidget.vue b/components/publish/PublishWidget.vue index 9feea9fe..cc4e653b 100644 --- a/components/publish/PublishWidget.vue +++ b/components/publish/PublishWidget.vue @@ -27,7 +27,7 @@ const emit = defineEmits<{ const { t } = useI18n() const draftState = useDraft(draftKey, initial) -const { draft, isEmpty } = $(draftState) +const { draft } = $(draftState) const { isExceedingAttachmentLimit, isUploading, failedAttachments, isOverDropZone, @@ -48,8 +48,6 @@ const { editor } = useTiptap({ set: (newVal) => { draft.params.status = newVal draft.lastUpdated = Date.now() - if (isEmpty) - clearEmptyDrafts() }, }), placeholder: computed(() => placeholder ?? draft.params.inReplyToId ? t('placeholder.replying') : t('placeholder.default_1')), diff --git a/composables/masto/statusDrafts.ts b/composables/masto/statusDrafts.ts index ec3c0391..58596f32 100644 --- a/composables/masto/statusDrafts.ts +++ b/composables/masto/statusDrafts.ts @@ -30,7 +30,7 @@ export function getDefaultDraft(options: Partial