Error when adding member to project on git.drupalcode.org w
>>> [!note] Migrated issue
<!-- Drupal.org comment -->
<!-- Migrated from issue #3310966. -->
Reported by: [pvbergen](https://www.drupal.org/user/3523184)
>>>
<h3 id="summary-problem-motivation">Problem/Motivation</h3>
<p>When I try to add a new member to a project at git.drupalcode.org/project/XXX/-/project_members, the XHR request fails. This happens to all tested users and when selecting any role.</p>
<p>The console reports a xhr Post+Preflight request to <a href="https://git.drupalcode.org/api/v4/projects/XXXXX/invitations">https://git.drupalcode.org/api/v4/projects/XXXXX/invitations</a>, which returns a 301 redirect to <a href="https://www.drupal.org/git-error">https://www.drupal.org/git-error</a>. This then is reported as a CORS error. It seems the redirect and CORS error is actually just a symptom of the error happening at the invitations endpoint.</p>
<h4 id="summary-steps-reproduce">Steps to reproduce</h4>
<p>- Open the member overview of a project at git.drupalcode.org<br>
- Click add member, select a user and role, hit "Invite"<br>
- The dialog will report that something went wrong.</p>
issue