web: only open trash item if it is a note

This commit is contained in:
Abdullah Atta
2022-11-07 13:12:43 +05:00
committed by Abdullah Atta
parent 860e97c97d
commit 84a687d69d

View File

@@ -51,7 +51,8 @@ function TrashItem({ item, index, date }) {
}
menu={{ items: menuItems, extraData: { item } }}
onClick={() => {
hashNavigate(`/notes/${item.id}/edit`, { replace: true });
if (item.itemType === "note")
hashNavigate(`/notes/${item.id}/edit`, { replace: true });
}}
/>
);