Conversation
There was a problem hiding this comment.
Pull request overview
This pull request changes the default behavior of the PRELOAD_RACE_DIAL environment variable so that preloading race dialing is disabled by default and only enabled when explicitly set to 1 or true, with accompanying documentation and changelog updates.
Changes:
- Default
预加载竞速拨号tofalseand require explicitPRELOAD_RACE_DIAL=1|trueto enable it. - Update README environment variable documentation for the new default/enable semantics.
- Add a changelog entry and bump the embedded version timestamp.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| README.md | Updates PRELOAD_RACE_DIAL documentation to reflect “off by default; enable with 1/true”. |
| CHANGELOG | Adds a release note entry describing the PRELOAD_RACE_DIAL default change. |
| _worker.js | Switches default preloading behavior to disabled and updates the env var parsing logic. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| const 访问路径 = url.pathname.slice(1).toLowerCase(); | ||
| 调试日志打印 = ['1', 'true'].includes(env.DEBUG) || 调试日志打印; | ||
| 预加载竞速拨号 = !['0', 'false'].includes(String(env.PRELOAD_RACE_DIAL ?? '').trim().toLowerCase()); | ||
| 预加载竞速拨号 = ['1', 'true'].includes(env.PRELOAD_RACE_DIAL) || 预加载竞速拨号; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request updates the logic for the
PRELOAD_RACE_DIALenvironment variable, changing its default behavior from enabled to disabled. Now, preloading for race dialing is off by default and must be explicitly enabled by setting the variable to1ortrue. The documentation inREADME.mdand the changelog have been updated to reflect this change.Environment Variable Logic Changes:
PRELOAD_RACE_DIALtofalse(preloading race dialing is now off by default); it will only be enabled if set to1ortrue. (_worker.js,README.md) [1] [2] [3]Documentation Updates:
README.mdto clarify the new default and usage ofPRELOAD_RACE_DIAL.Versioning:
_worker.jsto reflect the new release date.