mirror of
https://github.com/discourse/discourse.git
synced 2024-11-28 01:25:06 +08:00
fix code styling
This commit is contained in:
parent
a89e7ab662
commit
185f4bd8c8
|
@ -105,8 +105,7 @@ Discourse.Formatter = (function(){
|
|||
|
||||
// http://stackoverflow.com/questions/196972/convert-string-to-title-case-with-javascript
|
||||
// TODO: locale support ?
|
||||
toTitleCase = function toTitleCase(str)
|
||||
{
|
||||
toTitleCase = function toTitleCase(str) {
|
||||
return str.replace(/\w\S*/g, function(txt){
|
||||
return txt.charAt(0).toUpperCase() + txt.substr(1).toLowerCase();
|
||||
});
|
||||
|
@ -114,7 +113,6 @@ Discourse.Formatter = (function(){
|
|||
|
||||
longDate = function(dt) {
|
||||
if (!dt) return;
|
||||
|
||||
return moment(dt).longDate();
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user