Commit db81176c authored by addyosmani's avatar addyosmani

Switching to the latest version of dependencies, fixing routing bug after the update.

parent 09734912
......@@ -55,8 +55,8 @@
</script>
<script src="../../assets/jquery.min.js"></script>
<script src="js/lib/underscore.js"></script>
<script src="js/lib/backbone.js"></script>
<script src="js/lib/underscore-min.js"></script>
<script src="js/lib/backbone-min.js"></script>
<script src="js/lib/backbone-localstorage.js"></script>
<script src="js/init.js"></script>
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -4,25 +4,24 @@
// Todo Router
// ----------
var Router = Backbone.Router.extend({
var Workspace = Backbone.Router.extend({
routes:{
"/:filter": "setFilter",
"/:*": "setFilter"
"*filter": "setFilter"
},
setFilter: function(param){
// Set the current filter to be used
window.app.TodoFilter = param || "";
window.app.TodoFilter = param.trim() || "";
// Trigger a collection reset/addAll
window.app.Todos.trigger('reset');
}
});
window.app.TodoRouter = new Router;
window.app.TodoRouter = new Workspace;
Backbone.history.start();
})();
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment