title: Laravel - Queued cookies and middleware
body: <p>Adding a cookie in the cookies queued of laravel lead to have them in the queue in the next response...</p>
  
  <pre><code>Cookie::queue(cookie('test', 'test', 1));
  return $next($request);
  ... 
  Controller things
  ...
  View
  {{ dd(Cookie::getQueuedCookies()) }}
  </code></pre>
  
  <p>which show : </p>
  
  <pre><code>array:1 [
     'test' =&gt; Cookie{...}
  ]
  </code></pre>
  
  <p>Is there no way of setting a cookie for the next response than adding</p>
  
  <pre><code>next($request-&gt;cookie(cookie(...)));
  </code></pre>
  
  <p>in the middleware ?</p>