Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Moving a request from a collection to another persists old collection authentication #200

Open
1 task done
ehabhosam opened this issue Nov 30, 2024 · 0 comments
Open
1 task done
Labels
bug Something isn't working

Comments

@ehabhosam
Copy link

What happened?

When I drag and drop a request from a collection that has some applied authentication headers, to another collection that has different authentication, the request gets sent with the old collection headers and does not get updated.

Steps to reproduce?

1. Create 2 collections with different authentication headers that give different permissions. 
2. Make a request from the first collection (that has permissions to do it), it should work normally. 
3. Drag the request and drop it into the other collection. 
4. Although the second collection is not granted permissions to do the request, the request will work as it worked in step 2.

What did you expect to happen?

I expected the request to be done with the new collection headers.

Platform

Linux

HTTPie Desktop version

2024.1.2

Relevant log output

The bearer token I provided into the new collection: 

eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6ImdvYXRtb2Rlc3RlIiwiaWQiOiI0OWU5ZDk0Ni1kMGRjLTRjZDctOTlhNS02YTk3NGJmODJjZWMiLCJyb2xlIjoiQlJBTkNIX01BTkFHRVIiLCJpYXQiOjE3MzI5ODMzNTcsImV4cCI6MTczNTU3NTM1N30._qnD8Btol0-hdjDu9e5bJUjEcCa6kplobCrAk2dC-98

and here is the done request code (from the preview), just look at the bearer token:

POST /transaction/transfer HTTP/1.1
Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6Imxlb21lc3NpIiwiaWQiOiI0NmVmZmU0OC0wYmM0LTRlNzktOWQ2Ny0zZWVjN2VlMzYxNWEiLCJyb2xlIjoiQlJBTkNIX01BTkFHRVIiLCJpYXQiOjE3MzI4OTA3ODUsImV4cCI6MTczNTQ4Mjc4NX0.AI50ndm0uYJ_vcWl0tX1yUMo_UIJhf_etYu6q8Ctx3Y
Content-Length: 179
Content-Type: application/json
Host: localhost:5050
User-Agent: HTTPie

{
  "productId": 2,
  "amount": 26,
  "branchId": "1ff8c55a-f45d-4068-baa5-37db44f7c849",
  "type": "TRANSFER", 
  "destinationBranchId": "f2e1644e-a6dc-4337-90b1-ead4fb5ee6b1"
}

Code of Conduct

  • I agree to follow this project's Code of Conduct
@ehabhosam ehabhosam added the bug Something isn't working label Nov 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant