ma1 pushed to branch tor-browser-115.16.0esr-13.5-1 at The Tor Project / Applications / Tor Browser
Commits:
-
67f0b6ff
by hackademix at 2024-10-17T22:22:46+02:00
1 changed file:
Changes:
... | ... | @@ -169,8 +169,17 @@ const ClipboardPrivacy = { |
169 | 169 | return trans;
|
170 | 170 | },
|
171 | 171 | _computeClipboardHash() {
|
172 | + const flavors = ["text/x-moz-url", "text/plain"];
|
|
173 | + if (
|
|
174 | + !Services.clipboard.hasDataMatchingFlavors(
|
|
175 | + flavors,
|
|
176 | + Ci.nsIClipboard.kGlobalClipboard
|
|
177 | + )
|
|
178 | + ) {
|
|
179 | + return null;
|
|
180 | + }
|
|
172 | 181 | const trans = this._createTransferable();
|
173 | - ["text/x-moz-url", "text/plain"].forEach(trans.addDataFlavor);
|
|
182 | + flavors.forEach(trans.addDataFlavor);
|
|
174 | 183 | try {
|
175 | 184 | Services.clipboard.getData(trans, Ci.nsIClipboard.kGlobalClipboard);
|
176 | 185 | const clipboardContent = {};
|