mirror of
https://github.com/vale981/Vulcan
synced 2025-03-06 10:01:40 -05:00
Fix “post awaiting moderation” message
This commit is contained in:
parent
201af43cf9
commit
6868a69f3e
3 changed files with 8 additions and 2 deletions
|
@ -2,6 +2,9 @@
|
|||
|
||||
* Adeed Grid Layout option.
|
||||
* Cleaned up vote click handling functions and added tests (thanks @anthonymayer!).
|
||||
* Added `threadModules` zone.
|
||||
* Added `upvoteCallbacks` and `downvoteCallbacks` callback arrays.
|
||||
* Fix “post awaiting moderation” message bug.
|
||||
|
||||
## v0.13.0 “ComponentScope”
|
||||
|
||||
|
|
|
@ -29,10 +29,10 @@ AutoForm.hooks({
|
|||
onSuccess: function(operation, post, template) {
|
||||
template.$('button[type=submit]').removeClass('loading');
|
||||
trackEvent("new post", {'postId': post._id});
|
||||
Router.go('post_page', {_id: post._id});
|
||||
if (post.status === STATUS_PENDING) {
|
||||
flashMessage(i18n.t('thanks_your_post_is_awaiting_approval'), 'success');
|
||||
}
|
||||
Router.go('post_page', {_id: post._id});
|
||||
},
|
||||
|
||||
onError: function(operation, error, template) {
|
||||
|
|
|
@ -149,10 +149,13 @@ Meteor.startup( function (){
|
|||
|
||||
});
|
||||
|
||||
// onRun Hooks
|
||||
|
||||
Router.onRun(filters.clearSeenMessages);
|
||||
|
||||
// Before Hooks
|
||||
|
||||
Router.onBeforeAction(filters.isReady);
|
||||
Router.onBeforeAction(filters.clearSeenMessages);
|
||||
Router.onBeforeAction(filters.canView, {except: ['atSignIn', 'atSignUp', 'atForgotPwd', 'atResetPwd', 'signOut']});
|
||||
Router.onBeforeAction(filters.hasCompletedProfile);
|
||||
Router.onBeforeAction(filters.isLoggedIn, {only: ['post_submit', 'post_edit', 'comment_reply', 'comment_edit']});
|
||||
|
|
Loading…
Add table
Reference in a new issue