API: Restore backward-compatibility for POST /projects/:id/members when membership is locked

Merged Rémy Coutable requested to merge 971-confidential-issue into master

Closes #971 (closed).

/cc @rdavila