title: Can not get the current language to appear in the widget
body: <p>Hi I have a problem with a couple of widgets on my Wordpress site. It always takes the first language (english ) instead of the correct language that the page is on at that moment. </p>
  
  <p>Here is my code from one of the widgets:</p>
  
  <pre><code>&lt;?php
  if ( is_active_sidebar('logostrip') ) {
  
      $widgets    = wp_get_sidebars_widgets(true, true, 'logostrip', true);
      $logoWidget = $widgets['logostrip'];
      $langs      = count(pll_languages_list());
      $currentLang = pll_current_language();
  
      for ($i=0; $i &lt; $langs; $i++) {
          if ( $logoWidget[$i] ) {
              $logoId     = $logoWidget[$i];
              $i = $langs;
          }
      }
  
      $title       = get_field('header', 'widget_' . $logoId);
      $title       = preg_replace(array('/\[/', '/\]/'), array('&lt;', '&gt;'), $title);
      $logos       = get_field('client_logos', 'widget_' . $logoId);
      $maxItems    = 6;
  </code></pre>
  
  <p>?></p>
  
  <p>Could anybody help me with this? I have already implemented this so that it would take the current language but nothing happens.</p>
  
  <pre><code>$currentLang = ppl_current_language();
  </code></pre>
  
  <p>Thank you!</p>