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

Error while checking if creator id is equal to the logged in userId #233

Closed
XshubhamX opened this issue Apr 20, 2021 · 3 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@XshubhamX
Copy link
Contributor

Describe the bug
While making a new admin of an organization .There is a creatorCheck which checks if the userId from token is equal to the creator id in Organization. But there is a bug in approch where the check is being made, We are comparing creator with userId but initially the creator id is of type object and userId is of type string so even if there values are same ,they will not pass the test because there datatypes are different.

image
Console log shows the datatypes are different

image

There is also a need to change some console log messages , at some places they are not giving relevant information.

Steps to resolve

If we change the data type of creator to staring the problem can be resolved.

Can i work on this issue @Sagar2366 Sir.

@github-actions github-actions bot added bug Something isn't working unapproved Unapproved for Pull Request labels Apr 20, 2021
@ssaumyaa7
Copy link
Contributor

Hello, can I work on this issue ?

Solution:
The datatype of creatorid and userid should be the same.

@palisadoes palisadoes removed the unapproved Unapproved for Pull Request label May 14, 2021
@ssaumyaa7
Copy link
Contributor

@palisadoes

bugfix done.... created pull request #240

@XshubhamX
Copy link
Contributor Author

@palisadoes sir this issue can be closed now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants