1
0
mirror of https://github.com/jhillyerd/inbucket.git synced 2025-12-18 18:17:03 +00:00

Handle empty subject lines in bootstrap

This commit is contained in:
James Hillyerd
2016-03-06 16:30:51 -08:00
parent ff460309e5
commit f16debebbf
3 changed files with 15 additions and 6 deletions

View File

@@ -107,10 +107,17 @@ function onDocumentReady() {
// Prevent search and resize handlers being called too often
var searchDelay = makeDelay(200);
var resizeDelay = makeDelay(100);
$.addTemplateFormatter("DateFormatter",
function(value, template) {
return moment(value).calendar();
});
$.addTemplateFormatter({
"date": function(value, template) {
return moment(value).calendar();
},
"subject": function(value, template) {
if (value == null || value.length == 0) {
return "(No Subject)";
}
return value;
}
});
$("#message-list").hide();
onWindowResize();
$(window).resize(function() {