diff --git a/demo/modelist.html b/demo/modelist.html
index 99b02e8a..659e3805 100644
--- a/demo/modelist.html
+++ b/demo/modelist.html
@@ -36,7 +36,7 @@
// set the editor mode. Webmasters could use it in their scripts
// for site specific purposes as well.
var filePath = 'blahblah/weee/some.js';
- var mode = modelist.getModeFromPath(filePath).mode;
+ var mode = modelist.getModeForPath(filePath).mode;
console.log(mode);
editor.session.setMode(mode);
}());