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

fix: allow moderators see role assigned users; fix #13301 #13315

Merged
merged 1 commit into from
Feb 16, 2024

Conversation

Hoto-Cocoa
Copy link
Contributor

@Hoto-Cocoa Hoto-Cocoa commented Feb 15, 2024

What

This PR changes /admin/roles/users API can be access by moderators, which reported as bug in #13301.

Why

See #13301 to more details.

Additional info (optional)

Checklist

  • Read the contribution guide
  • Test working in a local environment
  • (If needed) Add story of storybook
  • (If needed) Update CHANGELOG.md
  • (If possible) Add tests

@github-actions github-actions bot added the packages/backend Server side specific issue/PR label Feb 15, 2024
Copy link

codecov bot commented Feb 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (339acd2) 79.11% compared to head (a7f13de) 79.23%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master   #13315      +/-   ##
==========================================
+ Coverage   79.11%   79.23%   +0.12%     
==========================================
  Files         951      952       +1     
  Lines      104319   104383      +64     
  Branches     8359     8385      +26     
==========================================
+ Hits        82529    82705     +176     
+ Misses      21790    21678     -112     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

このPRによるapi.jsonの差分

差分はこちら

Get diff files from Workflow Page

@Hoto-Cocoa
Copy link
Contributor Author

I've done test.

The only problem is moderators can see all roles, not only roles that can be assigned by moderators.

@syuilo syuilo merged commit 2b41b1f into misskey-dev:master Feb 16, 2024
17 checks passed
@syuilo
Copy link
Member

syuilo commented Feb 16, 2024

🙏🏻

@Hoto-Cocoa Hoto-Cocoa deleted the patch-1 branch February 16, 2024 06:34
@anatawa12
Copy link
Member

これ間違ってmasterにマージしちゃってるのでdevelopにリベースしてmasterからdropしたほうがいいかも

@Hoto-Cocoa
Copy link
Contributor Author

これ間違ってmasterにマージしちゃってるのでdevelopにリベースしてmasterからdropしたほうがいいかも

会社での習慣通りマスターにPRを送ってしまいました。 私がしなければならないことがありますか?

@anatawa12
Copy link
Member

Hotoさんがするべきことはないと思います。

@Hoto-Cocoa
Copy link
Contributor Author

Hotoさんがするべきことはないと思います。

確認しました。 ありがとうございます。
貢献したという内訳が残っているのが良いので、これだけうまくいけばどうなってもいいです。

@anatawa12
Copy link
Member

anatawa12 commented Feb 16, 2024

貢献したという内訳が残っているのが良いので、これだけうまくいけばどうなってもいいです。

rebaseするときにはAuthorとして残ると思われます。

(gitでは変更の作者であるauthorとcommit作った人であるcommitterが独立して記録されます。)

追記: 作業者はAuthorが残るようにしてください。git cherry-pickかgit rebaseを用いると問題なく行われます。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
packages/backend Server side specific issue/PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants