Support » Plugin: The Events Calendar » Possible bug with custom query

  • mailme.eva


    Hi there!
    I am not sure, but I think I might have found a bug.

    I created a custom query with the following args:

    	$args = array(
    	  //order by startdate from newest to oldest
    	  //required in 3.x
    	  'meta_query' => array(
    				'key'     => '_EventStartDate',
    				'value'   => $query['end_date'],
    				'compare' => '<='
    				'key'     => '_EventEndDate',
    				'value'   => $query['start_date'],
    				'compare' => '>='

    Turns out that the meta_key set to ‘_EventEndDate’ sets both response fields, ‘EventStartDate’ and ‘EventEndDate’ to the value of ‘_EventEndDate’.
    If I set it to ‘_EventStartDate’, both fields show the expected values.

Viewing 1 replies (of 1 total)
  • Thanks for pointing this out!

    I’m not sure if this is a bug, as The Events Calendar events need to have a start date.

    Take care,
    Ed 🤟

Viewing 1 replies (of 1 total)
  • The topic ‘Possible bug with custom query’ is closed to new replies.