mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-13 17:17:28 +02:00
chore(v2): Fix more linter warnings (#4450)
This commit is contained in:
parent
3422f80a9a
commit
83d043ecb3
27 changed files with 116 additions and 85 deletions
|
@ -121,7 +121,7 @@ export const getActiveDocContext = (
|
|||
data.versions.forEach((version) => {
|
||||
version.docs.forEach((doc) => {
|
||||
if (doc.id === docId) {
|
||||
result[version.name!] = doc;
|
||||
result[version.name] = doc;
|
||||
}
|
||||
});
|
||||
});
|
||||
|
@ -157,7 +157,7 @@ export const getDocVersionSuggestions = (
|
|||
const isNotOnLatestVersion = activeDocContext.activeVersion !== latestVersion;
|
||||
|
||||
const latestDocSuggestion: GlobalDoc | undefined = isNotOnLatestVersion
|
||||
? activeDocContext?.alternateDocVersions[latestVersion.name!]
|
||||
? activeDocContext?.alternateDocVersions[latestVersion.name]
|
||||
: undefined;
|
||||
|
||||
const latestVersionSuggestion = isNotOnLatestVersion
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue