mirror of
https://github.com/streetwriters/notesnook.git
synced 2026-09-03 12:41:45 +02:00
hotfix: crash when moving an item to trash
This should probably be investigated more and fixed properly. Seems like a core issue to me.
This commit is contained in:
@@ -162,6 +162,8 @@ function Note(props) {
|
||||
export default React.memo(Note, function (prevProps, nextProps) {
|
||||
const prevItem = prevProps.item;
|
||||
const nextItem = nextProps.item;
|
||||
// TODO need to investigate why a crash happens here.
|
||||
if (!prevItem || !nextItem) return true;
|
||||
return (
|
||||
prevItem.pinned === nextItem.pinned &&
|
||||
prevItem.favorite === nextItem.favorite &&
|
||||
|
||||
Reference in New Issue
Block a user