add latest GHES release to path

This commit is contained in:
Sarah Schneider 2021-01-19 17:44:24 -05:00
Родитель a54c3ffd5a
Коммит ca395716c5
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -40,7 +40,7 @@ module.exports = function getDocsPathFromDeveloperPath (oldDeveloperPath, allRed
// oneoff redirect for a dotcom developer path to Enterprise-only path on docs.github.com // oneoff redirect for a dotcom developer path to Enterprise-only path on docs.github.com
const oauthAuthorizations = '/v3/oauth_authorizations' const oauthAuthorizations = '/v3/oauth_authorizations'
if (newPath.endsWith(oauthAuthorizations)) { if (newPath.endsWith(oauthAuthorizations)) {
newPath = newPath.replace(oauthAuthorizations, '/enterprise-server/v3/oauth_authorizations') newPath = newPath.replace(oauthAuthorizations, `/enterprise-server@${latest}/v3/oauth_authorizations`)
} }
// Change /v4/foo/bar to /v4/foo#bar // Change /v4/foo/bar to /v4/foo#bar