title: Laravel 8 Cookie retreiving wrong value
body: <p>we recently upgraded from older Laravel to Laravel 8 and cookies doesn't seem to work anymore.</p>
  <p>We have dynamically created links for translating website:</p>
  <pre><code>  &lt;a href=&quot;{{ URL::to('/translate') }}/{{ $language-&gt;language_code }}&quot;&gt;
  </code></pre>
  <p>In this route-&gt;function we create a cookie:</p>
  <pre><code>public function cookie_translate($id){
  
    Cookie::queue('translate', $id, 3000);
    return Redirect::route('index')-&gt;withCookie('translate');
  
  }
  </code></pre>
  <p>And in AppServiceProvider.php we retreive cookie:</p>
  <pre><code>if(!empty(Cookie::get('translate'))){
    $translate = Crypt::decrypt(Cookie::get('translate'), false);
    $lang_title['view'] = Languages::getLanguage($translate);
    $language_title = $lang_title['view']-&gt;language_name;
  }
  </code></pre>
  <p>But since upgrading, we keep getting this error:</p>
  <blockquote>
  <p>ErrorException Attempt to read property &quot;language_name&quot; on null</p>
  </blockquote>
  <p>Debugging we found out that, cookie get, brings in wrong value:</p>
  <pre><code>39d3fc269f0567accb5452b937f862ca771d4fc6|nl
  </code></pre>
  <p>It should be only <code>nl</code></p>
  <p>When researching, I only found posts from couple years ago, that no one has responded and have no positive answer.</p>