title: htaccess redirect doesn't work: Too many redirects
body: <p>How we can redirect an old URL with <code>//</code> to have only one <code>/</code></p>
  
  <p>From:</p>
  
  <pre><code>https://www.example.com/maincategory//subcategory/
  </code></pre>
  
  <p>To:</p>
  
  <pre><code>https://www.example.com/maincategory/subcategory/
  </code></pre>
  
  <p>This solution has too many redirects:</p>
  
  <pre><code>Redirect 301 /maincategory//subcategory/ /maincategory/subcategory/
  </code></pre>