mirror of
https://github.com/router-for-me/CLIProxyAPI.git
synced 2026-02-03 13:00:52 +08:00
refactor(access): migrate config-api-key provider to internal package
- Moved `config-api-key` provider logic from SDK to the internal `config_access` package. - Updated provider registration and initialization to ensure proper management via `Register` function. - Removed redundant `config-api-key` documentation, simplifying configuration examples. - Adjusted related imports and reconciliations for seamless integration with the new structure.
This commit is contained in:
@@ -6,6 +6,7 @@ package cliproxy
|
||||
import (
|
||||
"fmt"
|
||||
|
||||
configaccess "github.com/router-for-me/CLIProxyAPI/v6/internal/access/config_access"
|
||||
"github.com/router-for-me/CLIProxyAPI/v6/internal/api"
|
||||
"github.com/router-for-me/CLIProxyAPI/v6/internal/config"
|
||||
sdkaccess "github.com/router-for-me/CLIProxyAPI/v6/sdk/access"
|
||||
@@ -184,6 +185,8 @@ func (b *Builder) Build() (*Service, error) {
|
||||
if accessManager == nil {
|
||||
accessManager = sdkaccess.NewManager()
|
||||
}
|
||||
configaccess.Register()
|
||||
|
||||
providers, err := sdkaccess.BuildProviders(&b.cfg.SDKConfig)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
||||
Reference in New Issue
Block a user