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

ELY-2629: Move method permissionFor in IntNameSetPermissionCollection class #1963

Merged

Conversation

deepalik-neu
Copy link
Contributor

@deepalik-neu deepalik-neu commented Sep 22, 2023

@ashley-abdelsayed98
Copy link
Contributor

hi @deepalik-neu, thank you for your contribution! can you please link the JIRA issue in the PR description?

@Skyllarr
Copy link
Contributor

@deepalik-neu thank you so much Deepali! Just a minor, the commit message should include the jira issue number. Let us know if you need any help with that

@deepalik-neu
Copy link
Contributor Author

Thank you for letting me know.
https://issues.redhat.com/browse/ELY-2629

@Skyllarr
Copy link
Contributor

Skyllarr commented Sep 22, 2023

@deepalik-neu You can rename your commit by using "git commit --amend" and add an issue number there. Thank you!

@Skyllarr
Copy link
Contributor

Skyllarr commented Sep 22, 2023

@deepalik-neu good job! we just now need to squash the commits together. You can follow the steps from Sonia on slack :) You can start with the "git rebase -i HEAD~2"

@Skyllarr
Copy link
Contributor

Skyllarr commented Sep 22, 2023

@deepalik-neu I just noticed that 1 of your current commits is a "merge" commit. So unfortunately the usual interactive rebase with squash will not work. So please follow these steps to squash your commits:

git checkout 2.x
git checkout -b temp
git merge --squash move-permissionFor-method
git commit -m "[ELY-2629] Move method permissionFor in IntNameSetPermissionCollection class"
git branch -D move-permissionFor-method
git checkout -b move-permissionFor-method
git push -f yourRemoteName move-permissionFor-method

For explanation, see this stackoverflow response

@deepalik-neu deepalik-neu force-pushed the move-permissionFor-method branch from d11d3ad to d82fc6f Compare September 22, 2023 19:55
@deepalik-neu
Copy link
Contributor Author

Done. Thank you!

@@ -94,6 +90,10 @@ public boolean hasMoreElements() {
return bits != 0;
}

private Permission permissionFor(int id) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@deepalik-neu Just a total minor, since this method is private , can you please move it under all the public methods? It is our code style to have private methods located under the public methods. Thank you!

@Skyllarr
Copy link
Contributor

@deepalik-neu After you make the changes, you can use the git commit --amend and the change will be appended to the already existing commit, without creating a new one

@deepalik-neu deepalik-neu force-pushed the move-permissionFor-method branch from d82fc6f to c735f04 Compare September 22, 2023 20:15
Copy link
Contributor

@SoniaZaldana SoniaZaldana left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me! Thanks @deepalik-neu

@Skyllarr
Copy link
Contributor

@deepalik-neu There are some intermittent failures in the CI, those are unrelated to your changes. So I am re-running the jobs until they pass and then I can merge :)

@deepalik-neu
Copy link
Contributor Author

Thank you! @Skyllarr

@Skyllarr Skyllarr merged commit 7b6dbcd into wildfly-security:2.x Sep 22, 2023
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants