Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Better permission checks on assignment-related mutations #1612

Closed
wants to merge 3 commits into from

Conversation

schuyler1d
Copy link
Collaborator

@schuyler1d schuyler1d commented Jun 11, 2020

This makes a couple of plumbing changes:

  1. consolidating around assignmentRequiredOrAdminRole and removing assignmentRequired.
  2. removes unnecessary messageId querying now that there is no longer a maintained assignment_id in message table
  3. Fixes Feature Request: Super volunteers should be able to use message review #1488

Description

This cleans up some permission checks and plumbing. It's in-service of more upcoming assignment-related mutations (e.g. releaseAssignment for https://github.com/MoveOnOrg/Spoke/issues/1533) and also explicitly checks for TEXTER role in service of https://github.com/MoveOnOrg/Spoke/pull/1562 (cc: @JeremyParker )

Checklist:

  • I have manually tested my changes on desktop and mobile
  • The test suite passes locally with my changes
  • [na] If my change is a UI change, I have attached a screenshot to the description section of this pull request
  • My change is 300 lines of code or less, or has a documented reason in the description why it’s longer
  • [na] I have made any necessary changes to the documentation
  • I have added tests that prove my fix is effective or that my feature works

…s checking both TEXTER role and assignment OR ADMIN role

Also removes unnecessary messageId querying now that there is no longer a maintained assignment_id in message table
@schuyler1d schuyler1d added the S-on deck Status (ADMINS ONLY): PR label for those that will be added to the next stage label Jun 11, 2020
@schuyler1d schuyler1d added S-ready for stage-main (qa) Status (ADMINS ONLY): PR label for those ready to be added for stage: Approved, tests, etc and removed S-on deck Status (ADMINS ONLY): PR label for those that will be added to the next stage labels Jun 18, 2020
@schuyler1d schuyler1d closed this Jun 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-ready for stage-main (qa) Status (ADMINS ONLY): PR label for those ready to be added for stage: Approved, tests, etc
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant