Skip to content

Commit

Permalink
馃悰 Fix typebot and folder name update in dashboard
Browse files Browse the repository at this point in the history
Closes #1391
  • Loading branch information
baptisteArno committed Mar 26, 2024
1 parent 1f158e7 commit a48a211
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -192,5 +192,8 @@ export const ButtonSkeleton = () => (

export default memo(
FolderButton,
(prev, next) => prev.folder.id === next.folder.id && prev.index === next.index
(prev, next) =>
prev.folder.id === next.folder.id &&
prev.index === next.index &&
prev.folder.name === next.folder.name
)
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ export const FolderContent = ({ folder }: Props) => {
{folders &&
folders.map((folder, index) => (
<FolderButton
key={folder.id.toString()}
key={folder.id}
index={index}
folder={folder}
onFolderDeleted={refetchFolders}
Expand All @@ -205,7 +205,7 @@ export const FolderContent = ({ folder }: Props) => {
{typebots &&
typebots.map((typebot) => (
<TypebotButton
key={typebot.id.toString()}
key={typebot.id}
typebot={typebot}
draggedTypebot={draggedTypebot}
onTypebotUpdated={refetchTypebots}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -240,5 +240,8 @@ export default memo(
(prev, next) =>
prev.draggedTypebot?.id === next.draggedTypebot?.id &&
prev.typebot.id === next.typebot.id &&
prev.isReadOnly === next.isReadOnly
prev.isReadOnly === next.isReadOnly &&
prev.typebot.name === next.typebot.name &&
prev.typebot.icon === next.typebot.icon &&
prev.typebot.publishedTypebotId === next.typebot.publishedTypebotId
)

0 comments on commit a48a211

Please sign in to comment.