It turns out I made a redirection to my web so that it redirected the url without a bar to the url with a bar as long as it was not a file.
# si no existe un archivo que coincida con la solicitud...
RewriteCond %{REQUEST_FILENAME} !-f
# y si no termina con una barra, redireccionar a la misma dirección pero con la barra
RewriteRule ^(.*[^/]$) $1/ [R,QSA,L]
I found it on this page, but now I want that if you try to access the url with several bars, also redirect to the same url with a single bar.
Example:
www.mipagina.com/categoria/articulo-numero-201////
redirect to
www.mipagina.com/categoria/articulo-numero-201/