Skip to content

Commit

Permalink
Merge pull request #265 from seishun/remove-descending
Browse files Browse the repository at this point in the history
  • Loading branch information
feross committed Oct 27, 2020
2 parents a5e37ec + 5c53259 commit a3ed2dc
Showing 1 changed file with 0 additions and 5 deletions.
5 changes: 0 additions & 5 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -1555,11 +1555,6 @@ Buffer.prototype.copy = function copy (target, targetStart, start, end) {
if (this === target && typeof Uint8Array.prototype.copyWithin === 'function') {
// Use built-in when available, missing from IE11
this.copyWithin(targetStart, start, end)
} else if (this === target && start < targetStart && targetStart < end) {
// descending copy from end
for (var i = len - 1; i >= 0; --i) {
target[i + targetStart] = this[i + start]
}
} else {
Uint8Array.prototype.set.call(
target,
Expand Down

0 comments on commit a3ed2dc

Please sign in to comment.