refactor: clean up unused catch variables

This commit is contained in:
me
2026-05-08 10:33:25 +05:30
parent 7e79c6ca8b
commit 7fe67765d5
4 changed files with 97 additions and 93 deletions
@@ -122,7 +122,7 @@ export function ComposeCanvas({
// re-calculates height based on content and applies the zoom transform
const syncViewport = useCallback(() => {
if (!(fabricRef.current && wrapperRef.current)) return;
textboxRef.current.initDimensions();
textboxRef.current?.initDimensions();
const minHeight = initialData?.canvasHeight ?? DEFAULT_LOGICAL_HEIGHT;
logicalSizeRef.current.height = measureLogicalContentHeight(
@@ -63,7 +63,11 @@ export function PostSealModal({
type="button"
data-testid="view-letter-btn"
className="btn btn-primary btn-sm"
onClick={() => navigate(PATHS.read(sealedTargetId!))}
onClick={() => {
if (sealedTargetId) {
navigate(PATHS.read(sealedTargetId));
}
}}
>
View letter
</button>