diff --git a/packages/bruno-app/src/components/CollectionSettings/index.js b/packages/bruno-app/src/components/CollectionSettings/index.js index 5cc7c34e5..b849d6b18 100644 --- a/packages/bruno-app/src/components/CollectionSettings/index.js +++ b/packages/bruno-app/src/components/CollectionSettings/index.js @@ -40,7 +40,7 @@ const CollectionSettings = ({ collection }) => { }; const root = collection?.root; - const hasScripts = root?.request?.script.res || root?.request?.script.req; + const hasScripts = root?.request?.script?.res || root?.request?.script?.req; const hasTests = root?.request?.tests; const hasDocs = root?.docs; diff --git a/packages/bruno-app/src/components/FolderSettings/index.js b/packages/bruno-app/src/components/FolderSettings/index.js index dba5f170d..9c7dc087d 100644 --- a/packages/bruno-app/src/components/FolderSettings/index.js +++ b/packages/bruno-app/src/components/FolderSettings/index.js @@ -26,7 +26,7 @@ const FolderSettings = ({ collection, folder }) => { } const folderRoot = collection?.items.find((item) => item.uid === folder?.uid)?.root; - const hasScripts = folderRoot?.request?.script.res || folderRoot?.request?.script.req; + const hasScripts = folderRoot?.request?.script?.res || folderRoot?.request?.script?.req; const hasTests = folderRoot?.request?.tests; const headers = folderRoot?.request?.headers || [];