mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-08 17:30:09 +02:00
Enable the unicorn/prefer-at
ESLint plugin rule (PR 15008 follow-up)
Please find additional information here: - https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/at - https://github.com/sindresorhus/eslint-plugin-unicorn/blob/main/docs/rules/prefer-at.md
This commit is contained in:
parent
5d88233fbb
commit
9ac4536693
32 changed files with 56 additions and 46 deletions
|
@ -488,7 +488,7 @@ function expandBoundsLTR(width, bounds) {
|
|||
affectedBoundary.x2 > boundary.x2 ? affectedBoundary : boundary;
|
||||
if (lastBoundary === useBoundary) {
|
||||
// Merging with previous.
|
||||
changedHorizon[changedHorizon.length - 1].end = horizonPart.end;
|
||||
changedHorizon.at(-1).end = horizonPart.end;
|
||||
} else {
|
||||
changedHorizon.push({
|
||||
start: horizonPart.start,
|
||||
|
@ -507,7 +507,7 @@ function expandBoundsLTR(width, bounds) {
|
|||
});
|
||||
}
|
||||
if (boundary.y2 < horizon[j].end) {
|
||||
changedHorizon[changedHorizon.length - 1].end = boundary.y2;
|
||||
changedHorizon.at(-1).end = boundary.y2;
|
||||
changedHorizon.push({
|
||||
start: boundary.y2,
|
||||
end: horizon[j].end,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue