small changes in todo and in shortcode hook

This commit is contained in:
lenovo
2022-11-14 18:08:53 +01:00
parent beba3c5aab
commit 604cf884c6
2 changed files with 4 additions and 7 deletions

View File

@@ -155,7 +155,7 @@ add_shortcode('lejourduprof_map', 'mp_ljdp_map');
function mp_update_publish() {
$post_args = array(
'numberposts' => 1,
'numberposts' => -1,
//'post_status' => 'draft',
'post_status' => 'publish',
'post_type' => 'post',
@@ -216,9 +216,6 @@ function post_published_coordinates($id, $post) {
if ( ! add_post_meta( $id, 'location', $location, true ) )
update_post_meta( $id, 'location', $location );
if ( ! add_post_meta( $id, 'test', "ok", true ) )
update_post_meta( $id, 'test', "ok" );
}
add_action( 'publish_post', 'post_published_coordinates', 10, 2 );