@ -287,6 +287,9 @@ define(['taskbar'], function(taskbar) {
titleEl = composer.postContainer.querySelector('input'),
bodyEl = composer.postContainer.querySelector('textarea');
titleEl.value = titleEl.value.trim();
bodyEl.value = bodyEl.value.trim();
if (titleEl.value.length < 3) {
return app.alert({
type: 'error',
@ -184,6 +184,10 @@ var RDB = require('./redis.js'),
}
Posts.reply = function(socket, tid, uid, content, images) {
if(content) {
content = content.trim();
if (uid < 1) {
socket.emit('event:alert', {
title: 'Reply Unsuccessful',
@ -338,6 +338,11 @@ marked.setOptions({
if (!category_id)
throw new Error('Attempted to post without a category_id');
if(content)
if(title)
title = title.trim();
if (uid === 0) {
title: 'Thank you for posting',