www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit c89bb0448475dcf60ea97b86e8cf28f83db9a46d
parent b34299998345a9867cf59d9915ce04ac2623b874
Author: Dan Stillman <dstillman@zotero.org>
Date:   Fri, 20 Jan 2012 17:25:02 -0500

Add mappings for obsolete style ids

Diffstat:
Mchrome/content/zotero/xpcom/style.js | 11+++++++++++
1 file changed, 11 insertions(+), 0 deletions(-)

diff --git a/chrome/content/zotero/xpcom/style.js b/chrome/content/zotero/xpcom/style.js @@ -107,6 +107,17 @@ Zotero.Styles = new function() { * @param {String} id */ this.get = function(id) { + // Map some obsolete styles to current ones + var mappings = { + "http://www.zotero.org/styles/chicago-note": "http://www.zotero.org/styles/chicago-note-bibliography", + "http://www.zotero.org/styles/mhra_note_without_bibliography": "http://www.zotero.org/styles/mhra", + "http://www.zotero.org/styles/aaa": "http://www.zotero.org/styles/american-anthropological-association" + }; + if(mappings[id]) { + Zotero.debug("Mapping " + id + " to " + mappings[id]); + id = mappings[id]; + } + if(!_initialized) this.init(); return _styles[id] ? _styles[id] : false; }