Skip to content

Commit 90dcea9

Browse files
committed
take out putCorsRules|putBucktSourceConfig
1 parent 15f2d6a commit 90dcea9

File tree

3 files changed

+14
-79
lines changed

3 files changed

+14
-79
lines changed

examples/put_bucktSourceConfig.php

Lines changed: 0 additions & 31 deletions
This file was deleted.

examples/put_corsRules.php

Lines changed: 0 additions & 33 deletions
This file was deleted.

src/Qiniu/Storage/BucketManager.php

Lines changed: 14 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -507,7 +507,6 @@ public function deleteBucketEvent($bucket, $name)
507507
* 设置bucket的跨域信息,最多允许设置10条跨域规则。
508508
* 对于同一个域名如果设置了多条规则,那么按顺序使用第一条匹配的规则去生成返回值。
509509
* 对于简单跨域请求,只匹配 Origin;
510-
* 对于预检请求, 需要匹配 Origin、AllowedMethod、AllowedHeader;
511510
* allowed_orgin: 允许的域名。必填;支持通配符*;*表示全部匹配;只有第一个*生效;
512511
* 需要设置"Scheme";大小写敏感。例如
513512
* 规则:http://*.abc.*.com 请求:"http://test.abc.test.com" 结果:不通过
@@ -524,13 +523,13 @@ public function deleteBucketEvent($bucket, $name)
524523
* allowed_credentials:该配置不支持设置,默认为true。
525524
* 备注:如果没有设置任何corsRules,那么默认允许所有的跨域请求
526525
*/
527-
public function putCorsRules($bucket, $params)
528-
{
529-
$path = '/corsRules/set/' . $bucket;
530-
$data = json_encode($params);
531-
$info = $this->ucPost($path, $data);
532-
return $info;
533-
}
526+
// public function putCorsRules(string $bucket, array $params)
527+
// {
528+
// $path = '/corsRules/set/' . $bucket;
529+
// $data = json_encode($params);
530+
// $info = $this->ucPost($path, $data);
531+
// return $info;
532+
// }
534533

535534
/**
536535
* 获取bucket的跨域信息
@@ -558,13 +557,13 @@ public function getCorsRules($bucket)
558557
* 主备源会分开计算.
559558
* Backup 是否备用回源,回源优先尝试主源
560559
*/
561-
public function putBucktSourceConfig(array $params)
562-
{
563-
$path = '/mirrorConfig/set';
564-
$data = json_encode($params);
565-
$info = $this->ucPostV2($path, $data);
566-
return $info;
567-
}
560+
// public function putBucktSourceConfig(array $params)
561+
// {
562+
// $path = '/mirrorConfig/set';
563+
// $data = json_encode($params);
564+
// $info = $this->ucPostV2($path, $data);
565+
// return $info;
566+
// }
568567

569568
/**
570569
* 获取空间回源配置

0 commit comments

Comments
 (0)