Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/bruno-app/src/utils/auth/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ export const resolveInheritedAuth = (item, collection) => {
const collectionAuth = get(collectionRoot, 'request.auth', { mode: 'none' });
let effectiveAuth = collectionAuth;

// Walk ancestor folders from deepest up; pick the first one with a concrete auth mode (skip 'none'/'inherit').
// Walk ancestor folders from deepest up; pick the first one with a concrete auth mode (skip 'inherit').
for (let idx = requestTreePath.length - 1; idx >= 0; idx--) {
const i = requestTreePath[idx];
if (i.type === 'folder') {
const folderAuth = i?.draft ? get(i, 'draft.request.auth') : get(i, 'root.request.auth');
if (folderAuth && folderAuth.mode && folderAuth.mode !== 'none' && folderAuth.mode !== 'inherit') {
if (folderAuth && folderAuth.mode && folderAuth.mode !== 'inherit') {
effectiveAuth = folderAuth;
break;
}
Expand Down