diff --git a/plugins/tiddlywiki/tiddlyweb/tiddlyweb.js b/plugins/tiddlywiki/tiddlyweb/tiddlyweb.js index 2481a8ce9..b6b832898 100644 --- a/plugins/tiddlywiki/tiddlyweb/tiddlyweb.js +++ b/plugins/tiddlywiki/tiddlyweb/tiddlyweb.js @@ -202,6 +202,7 @@ Convert a TiddlyWeb JSON tiddler into a TiddlyWiki5 tiddler */ TiddlyWebSyncer.prototype.convertTiddler = function(tiddlerFields) { var result = {}; + // Transfer the fields, pulling down the `fields` hashmap for(var f in tiddlerFields) { switch(f) { case "fields": @@ -214,6 +215,12 @@ TiddlyWebSyncer.prototype.convertTiddler = function(tiddlerFields) { break; } } + // Some unholy freaking of content types + if(result.type === "text/javascript") { + result.type = "application/javascript"; + } else if(!result.type || result.type === "None") { + result.type = "text/x-tiddlywiki-old"; + } return result; };