Skip to content

Commit aa1c23a

Browse files
bolasblackIgorMinar
authored andcommitted
docs(versions): remove the trailing slash in URLs when switch versions
Because `https://docs.angularjs.org/api/` can handler the trailing slash, but `https://code.angularjs.org/1.2.24/docs/api` can not. Fix angular#9043 Closes angular#9045
1 parent 58e8c02 commit aa1c23a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/app/src/versions.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ angular.module('versions', [])
1919
};
2020

2121
$scope.jumpToDocsVersion = function(version) {
22-
var currentPagePath = $location.path();
22+
var currentPagePath = $location.path().replace(/\/$/, '');
2323

2424
// TODO: We need to do some munging of the path for different versions of the API...
2525

0 commit comments

Comments
 (0)