title: Wordpress ACF datepicker fields not working
body: <p>I created a "vacations" <code>custom-post-type</code> in which there are two custom fields -> "startdate" and "enddate". The field types are both "Date Picker" obviously.</p>
  
  <p>But for some reason I dont know, I'm not able to fetch these fields. It returns nothing or null.
  In my <code>functions.php</code> I have this:</p>
  
  <pre><code>function get_vacation_dates(){
    $startDate = get_field('vacation_start', false, false);
    $endDate = get_field('vacation_end', false, false);
  
    $start_date = new DateTime($startDate);
    $end_date = new DateTime($endDate);
  
    $args = array(
      'post_type' =&gt; array('ferieperioder'),
      'post_status' =&gt; array('publish'),
      'posts_per_page' =&gt; -1,
      'post__in' =&gt; $post-&gt;ID,
       'meta_key' =&gt; array(
          'key' =&gt; 'vacation_start',
          'value' =&gt; $startDate
       ),
       array(
          'key' =&gt; 'vacation_end',
          'value' =&gt; $endDate
       )      
    );
  
    $query = new WP_Query($args);
  
    echo json_encode($query);
    die();
  }
  
  add_action('wp_ajax_nopriv_get_vacation_dates', 'get_vacation_dates');
  add_action('wp_ajax_get_vacation_dates','get_vacation_dates');
  </code></pre>
  
  <p>I don't know if this is correct at all, since I want to get each vacation_period (there can be multiple "vacation"-posts) returned as json for some AJAX-handling. </p>
  
  <p>For example I want an json array like this:</p>
  
  <pre><code>[ {
      "vacation_name"  : "summer",
      "vacation_start" : "01-07-2019",
      "vacation_end" : "30-07-2019"
    },
    {
      "vacation_name"  : "winter",
      "vacation_start" : "01-12-2019",
      "vacation_end" : "14-12-2019"
    },
  ]
  </code></pre>
  
  <p>or something like that...</p>
  
  <p>How can I achieve that? </p>