Skip to content

Commit b12c5ed

Browse files
committed
同步服务在连接时允许URL重定向
1 parent 96921b2 commit b12c5ed

2 files changed

Lines changed: 5 additions & 0 deletions

File tree

publish/changeLog.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
- 优化kw歌单列表数据显示
44

5+
### 优化
6+
7+
- 同步服务在连接时允许URL重定向
8+
59
### 修复
610

711
- 修复 kg 搜索结果显示问题(#2782

src/main/modules/sync/client/client.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,7 @@ let client: LX.Sync.Client.Socket | null
151151
// let listSyncPromise: Promise<void>
152152
export const connect = (urlInfo: LX.Sync.Client.UrlInfo, keyInfo: LX.Sync.ClientKeyInfo) => {
153153
client = new WebSocket(`${urlInfo.wsProtocol}//${urlInfo.hostPath}/socket?i=${encodeURIComponent(keyInfo.clientId)}&t=${encodeURIComponent(aesEncrypt(SYNC_CODE.msgConnect, keyInfo.key))}`, {
154+
followRedirects: true,
154155
}) as LX.Sync.Client.Socket
155156
client.data = {
156157
keyInfo,

0 commit comments

Comments
 (0)