Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue 293: Prevent "Auto Draft" posts from being logged #316

Merged
merged 3 commits into from
Mar 10, 2014

Conversation

powelski
Copy link

@powelski powelski commented Mar 9, 2014

Fix #293

@frankiejarrett
Copy link
Contributor

@shadyvb Please review

@@ -190,6 +190,11 @@ public static function callback_deleted_post( $post_id ) {
return;
}

// Is auto draft?
if ( '0000-00-00 00:00:00' === $post->post_modified_gmt ) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@powelski I don't think this alone should be the way we define auto-drafts, can't we use 'auto-draft' === $post->post_status as per https://github.com/WordPress/WordPress/blob/master/wp-admin/includes/post.php#L473 ?
Skimming through WP code i find lots of references to the same check

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done in 0466b51

frankiejarrett added a commit that referenced this pull request Mar 10, 2014
Issue 293: Prevent "Auto Draft" posts from being logged
@frankiejarrett frankiejarrett merged commit 1111d85 into develop Mar 10, 2014
@frankiejarrett frankiejarrett deleted the issue-293 branch March 10, 2014 19:08
@powelski
Copy link
Author

@fjarrett Are you sure those dont't have trash status?

@frankiejarrett
Copy link
Contributor

@powelski According to what core is doing I thought it was auto-draft status.

@shadyvb
Copy link
Contributor

shadyvb commented Mar 11, 2014

+1 for checking up on core's way

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Prevent "Auto Draft" posts from being logged
3 participants