1
0
mirror of https://github.com/Jermolene/TiddlyWiki5 synced 2025-01-11 09:50:27 +00:00

Workaround Firefox "no element found" bug

See https://bugzilla.mozilla.org/show_bug.cgi?id=884693

Fixes #468
This commit is contained in:
Jermolene 2014-05-27 09:49:48 +01:00
parent a463859a28
commit da273be054

View File

@ -161,7 +161,8 @@ var Command = function(params,commander,callback) {
state.wiki.addTiddler(new $tw.Tiddler(state.wiki.getCreationFields(),fields,{title: title}));
var changeCount = state.wiki.getChangeCount(title).toString();
response.writeHead(204, "OK",{
Etag: "\"default/" + encodeURIComponent(title) + "/" + changeCount + ":\""
Etag: "\"default/" + encodeURIComponent(title) + "/" + changeCount + ":\"",
"Content-Type": "text/plain"
});
response.end();
}
@ -172,7 +173,9 @@ var Command = function(params,commander,callback) {
handler: function(request,response,state) {
var title = decodeURIComponent(state.params[0]);
state.wiki.deleteTiddler(title);
response.writeHead(204, "OK");
response.writeHead(204, "OK", {
"Content-Type": "text/plain"
});
response.end();
}
});