Merge pull request #5358 from maxrice/rest-api-report-fix

Clear cached API reports when deleting shop order transients
This commit is contained in:
Mike Jolley 2014-04-23 11:24:02 +01:00
commit c92975f018
1 changed files with 3 additions and 0 deletions

View File

@ -351,6 +351,9 @@ function wc_delete_shop_order_transients( $post_id = 0 ) {
}
}
// clear API report transient
$transients_to_clear[] = 'wc_admin_report';
// Clear transients where we have names
foreach( $transients_to_clear as $transient ) {
delete_transient( $transient );