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

Return type of adminRemoveGroup Mutation Resolver should be InterfaceGroupChat and not InterfaceMessage #1307

Closed
KrutikaBhatt opened this issue Apr 17, 2023 · 2 comments · Fixed by #1311
Assignees
Labels
bug Something isn't working unapproved Unapproved for Pull Request

Comments

@KrutikaBhatt
Copy link
Contributor

Describe the bug
The return type of adminRemoveGroup Mutation Resolver currently is InterfaceMessage. This function enables an admin to remove a group and returns the deleted GroupChat. Thus it should have a return type of InterfaceGroupChat. We are currently using @ts-ignore to disable this warning message.

To Reproduce
Steps to reproduce the behavior:

  1. Go to the file src\resolvers\Mutation\adminRemoveGroup.ts
  2. Remove the // @ts-ignore line

Expected behavior
This error should be resolved

Actual behavior
The following error shows up -

Type 'InterfaceGroupChat' is missing the following properties from type 'InterfaceMessage': text, imageUrl, videoUrl,createdAt, group

Screenshots
The error thrown is as follows:-
image

Potential internship candidates
Please read this if you are planning to apply for a Palisadoes Foundation internship PalisadoesFoundation/talawa#359

@KrutikaBhatt KrutikaBhatt added the bug Something isn't working label Apr 17, 2023
@github-actions github-actions bot added the unapproved Unapproved for Pull Request label Apr 17, 2023
@palisadoes
Copy link
Contributor

Do you want to work on this?

@KrutikaBhatt
Copy link
Contributor Author

Thank you, sir! Yes, I will work on it. I actually had some doubts about understanding certain codes for solving this issue. I will ask for help on slack

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

Successfully merging a pull request may close this issue.

2 participants