Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Mullvad Browser
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Dan Ballard
Mullvad Browser
Commits
6450a4e6
Commit
6450a4e6
authored
1 year ago
by
cypherpunks1
Committed by
Pier Angelo Vendrame
10 months ago
Browse files
Options
Downloads
Patches
Plain Diff
Bug 41881: Don't persist custom network requests on private windows
parent
a66667cf
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
devtools/client/netmonitor/src/components/new-request/HTTPCustomRequestPanel.js
+14
-5
14 additions, 5 deletions
...itor/src/components/new-request/HTTPCustomRequestPanel.js
with
14 additions
and
5 deletions
devtools/client/netmonitor/src/components/new-request/HTTPCustomRequestPanel.js
+
14
−
5
View file @
6450a4e6
...
...
@@ -4,6 +4,11 @@
"
use strict
"
;
const
lazy
=
{};
ChromeUtils
.
defineESModuleGetters
(
lazy
,
{
PrivateBrowsingUtils
:
"
resource://gre/modules/PrivateBrowsingUtils.sys.mjs
"
,
});
const
{
Component
,
createFactory
,
...
...
@@ -122,10 +127,12 @@ class HTTPCustomRequestPanel extends Component {
async
componentDidMount
()
{
let
{
connector
,
request
}
=
this
.
props
;
const
persistedCustomRequest
=
await
asyncStorage
.
getItem
(
"
devtools.netmonitor.customRequest
"
);
request
=
request
||
persistedCustomRequest
;
if
(
!
lazy
.
PrivateBrowsingUtils
.
isWindowPrivate
(
window
))
{
const
persistedCustomRequest
=
await
asyncStorage
.
getItem
(
"
devtools.netmonitor.customRequest
"
);
request
=
request
||
persistedCustomRequest
;
}
if
(
!
request
)
{
this
.
setState
({
_isStateDataReady
:
true
});
...
...
@@ -191,7 +198,9 @@ class HTTPCustomRequestPanel extends Component {
}
componentWillUnmount
()
{
asyncStorage
.
setItem
(
"
devtools.netmonitor.customRequest
"
,
this
.
state
);
if
(
!
lazy
.
PrivateBrowsingUtils
.
isWindowPrivate
(
window
))
{
asyncStorage
.
setItem
(
"
devtools.netmonitor.customRequest
"
,
this
.
state
);
}
}
handleChangeURL
(
event
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment