Skip to content

Commit

Permalink
fix sidebar file name issue in rename-version (#762)
Browse files Browse the repository at this point in the history
  • Loading branch information
rupeshparab authored and JoelMarcey committed Jun 12, 2018
1 parent a77ae95 commit a2b076b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/rename-version.js
Original file line number Diff line number Diff line change
Expand Up @@ -117,9 +117,9 @@ if (fs.existsSync(CWD + '/versioned_docs/version-' + currentVersion)) {
// if sidebar file exists for this version, rename sidebar file and rewrite
// doc ids in the file
let currentSidebarFile =
CWD + '/versioned_sidebars/version-' + currentVersion + '-sidebar.json';
CWD + '/versioned_sidebars/version-' + currentVersion + '-sidebars.json';
let newSidebarFile =
CWD + '/versioned_sidebars/version-' + newVersion + '-sidebar.json';
CWD + '/versioned_sidebars/version-' + newVersion + '-sidebars.json';
if (fs.existsSync(currentSidebarFile)) {
fs.renameSync(currentSidebarFile, newSidebarFile);
let sidebarContent = fs.readFileSync(newSidebarFile, 'utf8');
Expand Down

0 comments on commit a2b076b

Please sign in to comment.