From 208caed0c04789f65c5293a6cc5a6acfec598a3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9D=BC=ED=98=81?= Date: Tue, 25 Aug 2026 13:48:37 +0900 Subject: [PATCH 1/2] =?UTF-8?q?fix(afternote):=20=EC=B6=94=EC=96=B5=20?= =?UTF-8?q?=EB=85=B8=ED=8A=B8=20=EB=AF=B8=EB=94=94=EC=96=B4=20=EA=B0=A4?= =?UTF-8?q?=EB=9F=AC=EB=A6=AC=20=EC=B7=A8=EC=86=8C=EA=B0=80=20=EA=B8=B0?= =?UTF-8?q?=EC=A1=B4=20=EC=B2=A8=EB=B6=80=EB=A5=BC=20=EC=A7=80=EC=9A=B0?= =?UTF-8?q?=EC=A7=80=20=EC=95=8A=EA=B2=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 갤러리 런처가 취소 결과(`uri == null`)를 "선택 없음" 으로 그대로 흘려보내, 폼 갱신 콜백이 이미 붙어 있던 첨부를 null 로 덮어썼다. 같은 파일의 촬영 경로는 진작 성공했을 때만 반영하고 있었으니(`captured && uri != null`), 어긋난 쪽은 갤러리다. 첨부만 지우는 수단은 화면에 없어 취소로 지워진 값은 되돌릴 길이 없다. 장례식에 남길 영상은 로컬 pick 과 서버 prefill 이 `videoUrl` 한 칸을 겸해, 수정 모드에서는 취소 한 번이 `MediaInput.None` 으로 이어져 서버에 저장된 영상까지 떨어뜨렸다. `onPhotoSelected`/`onVideoSelected` 를 `(String?) -> Unit` → `(String) -> Unit` 으로 좁히고, 플랫폼이 주는 `Uri?` 는 런처 람다에서 바로 접는다. 널이 흘러드는 형태를 타입이 막고, `?.let` 안에서는 수신자가 `Uri` 로 좁혀져 `"null"` 문자열이 새는 갈래도 표현되지 않는다. 인자 반공변이라 호출부의 `setMemorialPhoto`/`setMemorialVideo` (`(String?) -> Unit`)는 그대로 들어간다. 첨부를 지우는 수단 자체는 이 범위 밖이다 — 별도 이슈로 분리한다. 검증: - `:feature:afternote:presentation:testDebugUnitTest` 31건 · `ktlintCheck` · `:app:compileDebugUnitTestKotlin` 통과. - 렌더링 변경이 없어 screenshot baseline 은 건드리지 않는다. closes #1113 --- .../author/editor/memorial/MemorialMediaSourceState.kt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/feature/afternote/presentation/src/main/kotlin/com/afternote/feature/afternote/presentation/author/editor/memorial/MemorialMediaSourceState.kt b/feature/afternote/presentation/src/main/kotlin/com/afternote/feature/afternote/presentation/author/editor/memorial/MemorialMediaSourceState.kt index 3e40dcb33c..c2ab3be06a 100644 --- a/feature/afternote/presentation/src/main/kotlin/com/afternote/feature/afternote/presentation/author/editor/memorial/MemorialMediaSourceState.kt +++ b/feature/afternote/presentation/src/main/kotlin/com/afternote/feature/afternote/presentation/author/editor/memorial/MemorialMediaSourceState.kt @@ -78,14 +78,14 @@ internal class MemorialMediaSourceState( * 이 인텐트를 쏠 때 Android 는 런타임 권한을 요구하지 않는다 — 촬영은 카메라 앱의 프로세스에서 일어나고 * 우리는 결과 파일만 받는다. 반대로 선언해 두면 그 순간부터 런타임 권한이 *필수* 가 된다. * - * @param onPhotoSelected 영정 사진 확정 URI. 갤러리 취소는 기존 동작을 유지해 null 로 전달된다. + * @param onPhotoSelected 영정사진 확정 URI. 취소·실패에는 호출되지 않는다 — 슬롯의 기존 값이 그대로 남는다. * @param onVideoSelected 장례식에 남길 영상 확정 URI. 위와 같다. */ @Composable internal fun rememberMemorialMediaSourceState( snackbarHostState: SnackbarHostState, - onPhotoSelected: (String?) -> Unit, - onVideoSelected: (String?) -> Unit, + onPhotoSelected: (String) -> Unit, + onVideoSelected: (String) -> Unit, ): MemorialMediaSourceState { val context = LocalContext.current val scope = rememberCoroutineScope() @@ -97,11 +97,11 @@ internal fun rememberMemorialMediaSourceState( val photoGalleryLauncher = rememberLauncherForActivityResult(ActivityResultContracts.PickVisualMedia()) { uri: Uri? -> - onPhotoSelected(uri?.toString()) + uri?.let { onPhotoSelected(it.toString()) } } val videoGalleryLauncher = rememberLauncherForActivityResult(ActivityResultContracts.PickVisualMedia()) { uri: Uri? -> - onVideoSelected(uri?.toString()) + uri?.let { onVideoSelected(it.toString()) } } val photoCaptureLauncher = rememberLauncherForActivityResult(ActivityResultContracts.TakePicture()) { captured: Boolean -> From 3cfc2f60b4633c18fddc0b207703174fe1a39547 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=9D=BC=ED=98=81?= Date: Wed, 26 Aug 2026 00:05:10 +0900 Subject: [PATCH 2/2] =?UTF-8?q?chore:=20head=20=EA=B0=B1=EC=8B=A0=20?= =?UTF-8?q?=E2=80=94=20=EC=B6=A9=EB=8F=8C=20=ED=95=B4=EC=86=8C=20=EB=92=A4?= =?UTF-8?q?=20CI=20=ED=8A=B8=EB=A6=AC=EA=B1=B0=20=EB=B3=B5=EA=B5=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 충돌 상태에서 push 된 머지 커밋(6a9d2edcc)은 `pull_request` 트리거를 놓쳤다. GitHub 이 그 시점에 `refs/pull/1116/merge` 를 만들지 못해 워크플로가 아예 생성되지 않았고, 충돌이 풀린 뒤에도 그 이벤트는 소급 발사되지 않는다(#1028). 9분간 mergeable 이 unknown 에 머물고 head 에 런 0건인 것을 확인하고 빈 커밋으로 head 를 갱신한다. 검증(6a9d2edcc 트리 기준, 이 커밋은 트리 동일): - :feature:afternote:presentation:testDebugUnitTest · ktlintCheck · :app:compileDebugUnitTestKotlin 통과.