title: Initializing my variable doesn't works by first click, but by second click it works
body: <p>if I enter an article number, for example 100100 and then click on the button, my array parent is empty, although it actually has to be overwritten by the method called. however, when I click the button a second time, the array is no longer empty. Why is that? I want my array to be overwritten after the first click.</p>
  <p>my javascript:</p>
  <pre><code>
  $(document).ready(function(){
      getAlleArtikelstücklisten();
  })
  
  function getAlleArtikelstücklisten(){
      $.ajax({
          url: &quot;http://localhost:8080/orderLists/open&quot;,
          type: 'GET',
          contentType: &quot;application/json&quot;,
          success: handleData
        });
  }
  function handleData(data){
      alleArtikelstücklisten=data;
      console.log(alleArtikelstücklisten);
  }
  </code></pre>