Create/Update/DestroyMLClass should be restricted to corpus admins
While looking over all the possible actions on projects, @mlbonhomme and I found that while element types or allowed metadata can only be managed by corpus admins, ML classes can be created, renamed or deleted by contributors. The frontend restricts this to admins, but the APIs also allow contributors.
The original issue for CreateMLClass
, #442 (closed), mentions corpus admins, but the issues for DestroyMLClass
(#768 (closed)) and UpdateMLClass
(#816 (closed)) do not mention any rights. I could not find any archives that could explain why we just switched to contributors instead. We should restrict ML classes back to corpus admins, as those are a part of project management and not annotation.