qiniu / qiniu/nodejs-sdk

typescript中interface PutPolicyOptions中确实参数forceSaveKey

Open
#388 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
590
Forks
191
PR merge metrics
No merged PRs in 30d

Description

    const options: PutPolicyOptions = {
      scope: this.option.bucket,
      // TODO SDK中没有forceSaveKey参数,SDK修改后需要修改
      // @ts-ignore
      forceSaveKey: true,
      saveKey: policy.name,
      insertOnly: 1,
      detectMime: 1,
      mimeLimit: policy.kind,
      fsizeLimit: policy.sizeMax,
      fsizeMin: policy.sizeMin,
    };
    const putPolicy = new PutPolicy(options);

index.ts 文件PutPolicyOptions接口中没有定义forceSaveKey参数

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Open index.ts and find the PutPolicyOptions interface. Add the forceSaveKey parameter shown in the issue so the PutPolicy construction no longer needs @ts-ignore; done means the example type-checks with the option declared.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
api, cloud
Issue type
Bug
Difficulty
1/5
Estimated time
Under an hour
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.