optimizing defineRoute in routes.js
This commit is contained in:
parent
cc0e19c6bd
commit
b4257bfda8
1 changed files with 2 additions and 4 deletions
|
@ -12,12 +12,10 @@ define([
|
|||
"listViewStyle",
|
||||
"dashboardcss"], function () {
|
||||
|
||||
function defineRoute(newRoute, dictionary) {
|
||||
var baseRoute = Emby.Page.baseUrl();
|
||||
function defineRoute(newRoute) {
|
||||
var path = newRoute.path;
|
||||
path = path.replace(baseRoute, "");
|
||||
console.log("Defining route: " + path);
|
||||
newRoute.dictionary = newRoute.dictionary || dictionary || "core";
|
||||
newRoute.dictionary = "core";
|
||||
Emby.Page.addRoute(path, newRoute);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue