-
Notifications
You must be signed in to change notification settings - Fork 974
lock/unlock icon disappears when downloading from a site #12248
Comments
I really want to work on this issue. As I can see it was fixed before for Muon version 4.5.24 (or it actually wasn't?) : |
@MargarytaChepiga let me check this issue quickly and will let you know asap |
Hello! I found two ways to fix this issue. Both of them work, but I am not sure if that's a correct way of fixing this issue. browser-laptop/js/stores/windowStore.js Line 312 in fbb45d2
If I will comment out lines from 314 till 316: The result will be: I checked if it works on:
But I noticed that those three lines were added on purpose in order to reset security state. The thing is when we click on download those lines of code executes and resets the security state, so isSecure becomes null etc. According to the tests though this is the expected behavior. When I comment out those three lines everything works perfectly. I also check the test plan for this since those lines were a part of the fix. Everything seems to work perfect and nothing have broken so far. However, I am not fully sure why do we need those lines but I have a strong feeling that we need them. @diracdeltas, I would really appreciate your help here. Since I am assuming those three lines are important and I shouldn't remove them, I found another solution. As I already mention windowState resets isSecure to null. And the reason why icon disappears is that we don't handle the situation when isSecure is null.
Here: If we add the check for null: However, this solution is not perfect too. Since the state get's reset, the certificate becomes undefined and disappears. Another thing that I have noticed is that icon and certificate are not disappearing when we want to download pdf, so I think that this is handled for the pdf. However, I am still trying to figure out where and how. Any help and suggestions are highly appreciated! |
@MargarytaChepiga thanks for the detailed report! I think the right solution is probably "don't reset the security state if the browser-laptop/js/stores/windowStore.js Line 309 in fbb45d2
you can start by |
Thank you so much @diracdeltas! That was very helpful!!! |
Closing per #13541 (comment) |
Description
When downloading (ex. from github.com/brave/browser-laptop/releases) the lock/unlock icon disappears from the URL bar.
Steps to Reproduce
Actual result:
Lock icon disappears
Expected result:
Lock icon should remain
Reproduces how often:
Easily
Brave Version
about:brave info:
Brave | 0.19.113
rev | 043c506
Muon | 4.5.25
Reproducible on current live release:
Yes, reproduced on 0.19.105
Additional Information
The text was updated successfully, but these errors were encountered: