Skip to content

Commit

Permalink
fix: correct rule set exclusion and import logic
Browse files Browse the repository at this point in the history
- Updated README to include Proxy RuleSet in exclusion list
- Corrected import and exclusion logic in CN and Proxy preset modules
- Removed unnecessary exclusion of CN RuleSet in Proxy module
  • Loading branch information
liblaf committed Aug 12, 2024
1 parent 36a373e commit cfc1fa6
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@
- exclude:
- [📵 RuleSet: ADs](#-ruleset-ads)
- [🔒 RuleSet: Private](#-ruleset-private)
- [🌐 RuleSet: Proxy](#-ruleset-proxy)

### 🌐 RuleSet: Proxy

Expand All @@ -73,7 +74,6 @@
- exclude:
- [📵 RuleSet: ADs](#-ruleset-ads)
- [🔒 RuleSet: Private](#-ruleset-private)
- [🇨🇳 RuleSet: CN](#-ruleset-cn)

### 🤖 RuleSet: AI

Expand Down
2 changes: 2 additions & 0 deletions src/sbr/preset/_cn.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
from sbr.geoip import GeoIP
from sbr.preset._ads import ads
from sbr.preset._private import private
from sbr.preset._proxy import proxy


@aiocache.cached()
Expand Down Expand Up @@ -33,4 +34,5 @@ async def cn() -> Rule:
)
rule -= await ads()
rule -= await private()
rule -= await proxy()
return rule
2 changes: 0 additions & 2 deletions src/sbr/preset/_proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

from sbr import GeoSite, Rule
from sbr.preset._ads import ads
from sbr.preset._cn import cn
from sbr.preset._private import private


Expand All @@ -24,5 +23,4 @@ async def proxy() -> Rule:
)
rule -= await ads()
rule -= await private()
rule -= await cn()
return rule

0 comments on commit cfc1fa6

Please sign in to comment.