| OLD | NEW |
| 1 /* | 1 /* |
| 2 * This file is part of Adblock Plus <https://adblockplus.org/>, | 2 * This file is part of Adblock Plus <https://adblockplus.org/>, |
| 3 * Copyright (C) 2006-present eyeo GmbH | 3 * Copyright (C) 2006-present eyeo GmbH |
| 4 * | 4 * |
| 5 * Adblock Plus is free software: you can redistribute it and/or modify | 5 * Adblock Plus is free software: you can redistribute it and/or modify |
| 6 * it under the terms of the GNU General Public License version 3 as | 6 * it under the terms of the GNU General Public License version 3 as |
| 7 * published by the Free Software Foundation. | 7 * published by the Free Software Foundation. |
| 8 * | 8 * |
| 9 * Adblock Plus is distributed in the hope that it will be useful, | 9 * Adblock Plus is distributed in the hope that it will be useful, |
| 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of | 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| (...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 462 }); | 462 }); |
| 463 }, | 463 }, |
| 464 | 464 |
| 465 /** | 465 /** |
| 466 * Generator serializing filter data and yielding it line by line. | 466 * Generator serializing filter data and yielding it line by line. |
| 467 */ | 467 */ |
| 468 *exportData() | 468 *exportData() |
| 469 { | 469 { |
| 470 // Do not persist external subscriptions | 470 // Do not persist external subscriptions |
| 471 let subscriptions = this.subscriptions.filter( | 471 let subscriptions = this.subscriptions.filter( |
| 472 s => !(s instanceof ExternalSubscription) | 472 s => !(s instanceof ExternalSubscription) && |
| 473 !(s instanceof SpecialSubscription && s.filters.length == 0) |
| 473 ); | 474 ); |
| 474 | 475 |
| 475 yield "# Adblock Plus preferences"; | 476 yield "# Adblock Plus preferences"; |
| 476 yield "version=" + formatVersion; | 477 yield "version=" + formatVersion; |
| 477 | 478 |
| 478 let saved = new Set(); | 479 let saved = new Set(); |
| 479 let buf = []; | 480 let buf = []; |
| 480 | 481 |
| 481 // Save subscriptions | 482 // Save subscriptions |
| 482 for (let subscription of subscriptions) | 483 for (let subscription of subscriptions) |
| (...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 773 else if (this.wantObj === false && val) | 774 else if (this.wantObj === false && val) |
| 774 this.curObj.push(val.replace(/\\\[/g, "[")); | 775 this.curObj.push(val.replace(/\\\[/g, "[")); |
| 775 } | 776 } |
| 776 finally | 777 finally |
| 777 { | 778 { |
| 778 Filter.knownFilters = origKnownFilters; | 779 Filter.knownFilters = origKnownFilters; |
| 779 Subscription.knownSubscriptions = origKnownSubscriptions; | 780 Subscription.knownSubscriptions = origKnownSubscriptions; |
| 780 } | 781 } |
| 781 } | 782 } |
| 782 }; | 783 }; |
| OLD | NEW |