title: Laravel 5.x route specific paths into single route
body: <p>I want to map both <code>/tasks</code> and <code>/tasks/create</code> into a single route.</p>
  
  <p><a href="https://stackoverflow.com/a/21970797">Currently the following works</a>:</p>
  
  <pre><code>Route::get('/tasks', 'TaskController@getAll');
  Route::get('/tasks/{url}', 'TaskController@getAll')
      -&gt;where('url', '(create)?');
  </code></pre>
  
  <p>But there is a code duplication that I want to avoid.</p>
  
  <p>The following works but also maps to <code>/</code> which I want to exclude:</p>
  
  <pre><code>Route::get('{url}', 'TaskController@getAll')
      -&gt;where('url', '(tasks|tasks/create)?');
  </code></pre>
  
  <p>Is there a way to only map those two paths without <code>/</code>?</p>