Server side checking of user input before allowing signup.

pull/168/head
Nathan Leniz 2015-03-09 18:39:00 +09:00
parent 25b14354ad
commit b7e73c90eb
1 changed files with 4 additions and 3 deletions

View File

@ -34,12 +34,13 @@
})
.done(function (data, textStatus, xhr) {
if (data.alreadyPosted) {
window.location = '/stories/' + data.storyURL;
window.location = data.storyURL;
} else {
window.location = '/stories/submit/url=' +
window.location = '/stories/submit/new-story?url=' +
encodeURIComponent(data.storyURL) +
'&title=' + encodeURIComponent(data.storyTitle) +
'&image=' + encodeURIComponent(data.storyImage)
'&image=' + encodeURIComponent(data.storyImage) +
'&description=' + encodeURIComponent(data.storyMetaDescription);
}
});
}