Uniform plugin .htaccess problem

I have placed these rules in my .htaccess to file to strip www, force https and force a trailing slash on the end of the URL Unfortunately this interferes with Uniform generating errors or success messages, and also submitting the form.

If you leave the form empty and hit submit, it reloads the page but doesn’t display error message. Filling in the form correctly has the same effect and no email is sent. The rules work for the rest of the site.

RewriteCond %{HTTP_HOST} ^www\. [NC,OR]
RewriteCond %{HTTPS} off
RewriteCond %{HTTP_HOST} ^(?:www\.)?(.+)$ [NC]
RewriteRule ^ https://%1%{REQUEST_URI} [R=301,L,NE]

RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !(.*)/$
RewriteCond %{REQUEST_FILENAME} !\.(gif|jpg|png|svg|jpeg|pdf|zip|css|js)$ [NC]
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1/ [L,R=301] 

Does anyone know why its breaking the form, and how to stop it?

I have also submitted a Github Issue on the plugins repository for this.

This has been solved. The solution is to amend the form action to include a slash like so:

<form class="form" id="hireus" action="<?= $page->url()?>/#hireus" method="post">