@aiyiran/myclaw 1.0.240 → 1.0.241

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -58,8 +58,7 @@
58
58
  return null;
59
59
  }
60
60
  var wsName = data.workspace_id || 'main';
61
- var wsPrefix = wsName === 'main' ? 'workspace' : 'workspace-' + wsName;
62
- return 'https://cdn.yiranlaoshi.com/' + claw + '/' + wsPrefix + '/' + assetPath;
61
+ return 'https://cdn.yiranlaoshi.com/' + claw + '/' + wsName + '/' + assetPath;
63
62
  }
64
63
 
65
64
  // ═══ 创建按钮 ═══
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@aiyiran/myclaw",
3
- "version": "1.0.240",
3
+ "version": "1.0.241",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "bin": {
package/patches/patch.js CHANGED
@@ -263,11 +263,11 @@ function patch() {
263
263
  );
264
264
  cspPatches.push('frame-src');
265
265
  }
266
- // 放开 connect-src,允许 fetch/XHR 到外部 https API
266
+ // 放开 connect-src,允许 fetch/XHR 到外部 https API(包括 CDN)
267
267
  if (needsConnectSrc) {
268
268
  content = content.replace(
269
269
  '"connect-src \'self\' ws: wss:"',
270
- '"connect-src \'self\' https: ws: wss:"'
270
+ '"connect-src \'self\' https: ws: wss: https://cdn.yiranlaoshi.com"'
271
271
  );
272
272
  cspPatches.push('connect-src');
273
273
  }