mirror of
https://github.com/songquanpeng/one-api.git
synced 2025-11-13 03:43:44 +08:00
🎨 Change the method of getting channel parameters
This commit is contained in:
@@ -63,7 +63,7 @@ func (p *BaiduProvider) GetRequestHeaders() (headers map[string]string) {
|
||||
}
|
||||
|
||||
func (p *BaiduProvider) getBaiduAccessToken() (string, error) {
|
||||
apiKey := p.Context.GetString("api_key")
|
||||
apiKey := p.Channel.Key
|
||||
if val, ok := baiduTokenStore.Load(apiKey); ok {
|
||||
var accessToken BaiduAccessToken
|
||||
if accessToken, ok = val.(BaiduAccessToken); ok {
|
||||
|
||||
Reference in New Issue
Block a user