Skip to content

PHP SDK undefined method Qiniu\Config::getRsHostV2() #400

Closed
@jeanli-mai

Description

@jeanli-mai

问题描述

  • 代码
function actionTest($fileName) {
    $auth = new Auth(QINIU_ACCESS_KEY, QINIU_SECRET_KEY);
    $bucketMgr = new BucketManager($auth);
    return $bucketMgr->stat($this->bucket, $fileName);
}
  • 报错
Error: Call to undefined method Qiniu\Config::getRsHostV2() in /workspace/project/src/vendor/qiniu/php-sdk/src/Qiniu/Storage/BucketManager.php:1019
Stack trace:
#0 /workspace/project/src/vendor/qiniu/php-sdk/src/Qiniu/Storage/BucketManager.php(608): Qiniu\Storage\BucketManager->rsGet('project-private-...', '/stat/xxxxx...')
#1 /workspace/project/src/backend/components/Qiniu.php(135): Qiniu\Storage\BucketManager->stat('project-private-...', '\xE6\x9C\x83\xE5\x93\xA1\xE5\xB0\x8E\xE5\x87\xBA_20...')
#2 /workspace/project/src/backend/utils/ExcelUtil.php(336): backend\components\Qiniu->test('\xE6\x9C\x83\xE5\x93\xA1\xE5\xB0\x8E\xE5\x87\xBA_20...')
之后还有,但是不方便展示

麻烦帮忙看下

相关信息

  • SDK 版本:v7.7.0
  • 框架版本:Yii 2.0.45

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions