We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 9d1ce0a commit c983dcdCopy full SHA for c983dcd
lib/url.js
@@ -22,7 +22,6 @@
22
'use strict';
23
24
const {
25
- ArrayPrototypeAt,
26
ArrayPrototypeJoin,
27
Boolean,
28
Int8Array,
@@ -922,7 +921,7 @@ Url.prototype.resolveObject = function resolveObject(relative) {
922
921
// If a url ENDs in . or .., then it must get a trailing slash.
923
// however, if it ends in anything else non-slashy,
924
// then it must NOT get a trailing slash.
925
- let last = ArrayPrototypeAt(srcPath, -1);
+ let last = srcPath[srcPath.length - 1];
926
const hasTrailingSlash = (
927
((result.host || relative.host || srcPath.length > 1) &&
928
(last === '.' || last === '..')) || last === '');
0 commit comments