mirror of
https://github.com/usebruno/bruno.git
synced 2024-11-24 17:03:47 +01:00
feat(#1667): None means None
This commit is contained in:
parent
fe5816eb9a
commit
2569a1389d
@ -32,19 +32,8 @@ const prepareRequest = (request, collectionRoot) => {
|
||||
headers: headers
|
||||
};
|
||||
|
||||
/**
|
||||
* 27 Feb 2024:
|
||||
* ['inherit', 'none'].includes(request.auth.mode)
|
||||
* We are mainitaining the old behavior where 'none' used to inherit the collection auth.
|
||||
*
|
||||
* Very soon, 'none' will be treated as no auth and 'inherit' will be the only way to inherit collection auth.
|
||||
* We will request users to update their collection files to use 'inherit' instead of 'none'.
|
||||
* Don't want to break ongoing CI pipelines.
|
||||
*
|
||||
* Hoping to remove this by 1 April 2024.
|
||||
*/
|
||||
const collectionAuth = get(collectionRoot, 'request.auth');
|
||||
if (collectionAuth && ['inherit', 'none'].includes(request.auth.mode)) {
|
||||
if (collectionAuth && request.auth.mode === 'none') {
|
||||
if (collectionAuth.mode === 'basic') {
|
||||
axiosRequest.auth = {
|
||||
username: get(collectionAuth, 'basic.username'),
|
||||
|
@ -30,20 +30,9 @@ const parseFormData = (datas, collectionPath) => {
|
||||
return form;
|
||||
};
|
||||
|
||||
/**
|
||||
* 27 Feb 2024:
|
||||
* ['inherit', 'none'].includes(request.auth.mode)
|
||||
* We are mainitaining the old behavior where 'none' used to inherit the collection auth.
|
||||
*
|
||||
* Very soon, 'none' will be treated as no auth and 'inherit' will be the only way to inherit collection auth.
|
||||
* We will request users to update their collection files to use 'inherit' instead of 'none'.
|
||||
* Don't want to break ongoing CI pipelines.
|
||||
*
|
||||
* Hoping to remove this by 1 April 2024.
|
||||
*/
|
||||
const setAuthHeaders = (axiosRequest, request, collectionRoot) => {
|
||||
const collectionAuth = get(collectionRoot, 'request.auth');
|
||||
if (collectionAuth && ['inherit', 'none'].includes(request.auth.mode)) {
|
||||
if (collectionAuth && request.auth.mode === 'inherit') {
|
||||
switch (collectionAuth.mode) {
|
||||
case 'awsv4':
|
||||
axiosRequest.awsv4config = {
|
||||
|
Loading…
Reference in New Issue
Block a user