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

hardcoded mdl_ prefix #1

Closed
danmarsden opened this issue Sep 19, 2017 · 0 comments
Closed

hardcoded mdl_ prefix #1

danmarsden opened this issue Sep 19, 2017 · 0 comments

Comments

@danmarsden
Copy link

Hi, just taking a quick look at this plugin for approval in the moodle.org plugins db - thanks for your patience with the review process!

it looks like you have hard-coded the mdl_ prefix in the sql here:
https://github.com/christos312/get_user_cohorts/blob/master/externallib.php#L65

you should be using curly braces around the table names as not all sites will use mdl_ as the prefix.

for example:
JOIN mdl_cohort_members AS hm
should be:
JOIN {cohort_members} AS hm

@ghost ghost self-assigned this Sep 19, 2017
@ghost ghost closed this as completed in d246207 Sep 19, 2017
This issue was closed.
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

No branches or pull requests

1 participant