Skip to content

Commit 0d6bc56

Browse files
committed
rename
1 parent 0e881a8 commit 0d6bc56

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/dokka-presets/scripts/custom-navigation-loader.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,12 +15,12 @@ function extractModulePath(href) {
1515
.filter(Boolean); // drop empty parts
1616

1717
// the URL pattern is always ".../kotlin/api/<version>/..."
18-
const apiPos = segments.indexOf('api');
19-
if (apiPos === -1) return null;
18+
const apiIndex = segments.indexOf('api');
19+
if (apiIndex === -1) return null;
2020

2121
// segment after "api" is the version ("latest", "1.4.109", etc.)
2222
// segment after _that_ is the module name (or "index.html" if we're at the root)
23-
return segments[apiPos + 2] ?? 'index.html';
23+
return segments[apiIndex + 2] ?? 'index.html';
2424
} catch {
2525
return null;
2626
}

0 commit comments

Comments
 (0)