Skip to content

Commit

Permalink
fix: hasOwn in node v10
Browse files Browse the repository at this point in the history
  • Loading branch information
zhengzuoyu.zzy committed Jan 5, 2024
1 parent 299f9d4 commit f8ec76f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/common/signUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ exports.getCanonicalRequest = function getCanonicalRequest(method, request, buck
// Canonical Headers
if (additionalHeaders) {
additionalHeaders.forEach(v => {
if (!Object.hasOwn(headers, v)) {
if (!Object.prototype.hasOwnProperty.call(headers, v)) {
throw Error(`Can't find additional header ${v} in request headers.`);
}
});
Expand Down
2 changes: 1 addition & 1 deletion test/node/multiversion.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ describe('test/multiversion.test.js', () => {
describe(`test multiversion in iterate ${idx}`, () => {
before(async () => {
store = oss({ ...config, ...moreConfigs });
bucket = `ali-oss-test-bucket-multiversion-${prefix.replace(/[/.]/g, '-').slice(0, -1)}${idx}`;
bucket = `ali-oss-test-bucket-version-${prefix.replace(/[/.]/g, '-')}${idx}`;

const result = await store.putBucket(bucket);
store.useBucket(bucket);
Expand Down

0 comments on commit f8ec76f

Please sign in to comment.