Allow captionless media posts while rejecting truly empty posts

Hop-State: A_06FPA2RFGPJ3QTNYV64F90R
Hop-Proposal: R_06FPA2PG7XQ9EJHPV0AMJHG
Hop-Task: T_06FPA1X78BHAFBEY6GBDNT0
Hop-Attempt: AT_06FPA1X78BRF2NXD1SDAYC0
This commit is contained in:
2026-07-15 02:10:51 -07:00
committed by Hop
parent 007ca453d2
commit 6dd3379fb4
5 changed files with 71 additions and 19 deletions
+6
View File
@@ -0,0 +1,6 @@
export function hasPublishablePostContent(
content: string,
mediaIds: readonly string[] | undefined,
): boolean {
return content.trim().length > 0 || (mediaIds?.length ?? 0) > 0;
}