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 error within API function which prevents user being subscribed to a channel #11

Closed
wants to merge 1 commit into from

Conversation

semteacher
Copy link

Found error:
$this->userapi->get_user
expected int but object was provided... So users were unable to suscribe. Fixed.

@adpe adpe self-assigned this Feb 24, 2022
@adpe adpe added the bug Something isn't working label Feb 24, 2022
@adpe
Copy link
Owner

adpe commented Feb 25, 2022

Thanks @semteacher, for your good catch and your merge request - really appreciate!

I've look to that issue and found an inconsistency which could be solved in two ways. As I dig in to the code, I saw that the user is called twice. Therefore, I've refactored slightly the logic and cleaned up the observers.

Can you please try out this branch https://github.com/adpe/moodle-local_rocketchat/tree/bugfix/12-user-subscriptions and let me know if it solves the problem at your end?

Greets
Adrian

@adpe adpe mentioned this pull request Feb 25, 2022
@adpe
Copy link
Owner

adpe commented Feb 25, 2022

This PR will be closed. Please follow #13

@adpe adpe closed this Feb 25, 2022
@adpe adpe added the invalid This doesn't seem right label Feb 25, 2022
@semteacher
Copy link
Author

Thank you @adpe to pay attention to this problem. Will try to check ASAP but do not know when - I am from Ukraine and we fight against russia invasion for now....

@adpe
Copy link
Owner

adpe commented Feb 25, 2022

Sad to hear about what's going on there! Please let me know in PR #13 or in the issue #12 if it will solve your problem.

If I'll have some spare time, I try to reproduce it and merge it if successful straight away and release a new plugin version.

Greets
Adrian

@adpe
Copy link
Owner

adpe commented Feb 28, 2022

Hi @semteacher

Could reproduce it and can verify that it's now working with Rocket.Chat 4.4.2. There were some other changes due to naming convention in channels as well, which breaks stuff...

Will release a new plugin version the next days.

Greets
Adrian

@semteacher
Copy link
Author

Hi @adpe
Nice to hear. Does not nave ability to work on this (even despite I am in relatively safe area)

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

Successfully merging this pull request may close these issues.

None yet

3 participants