Skip to content
Snippets Groups Projects
Commit 9c48b32c authored by Anisa's avatar Anisa
Browse files

make feature_of_purpose just for V4

parent 9a31279a
Branches
No related tags found
No related merge requests found
...@@ -29,6 +29,12 @@ require_once($CFG->dirroot . '/mod/pdfannotator/locallib.php'); ...@@ -29,6 +29,12 @@ require_once($CFG->dirroot . '/mod/pdfannotator/locallib.php');
* @return mixed True if module supports feature, false if not, null if doesn't know * @return mixed True if module supports feature, false if not, null if doesn't know
*/ */
function pdfannotator_supports($feature) { function pdfannotator_supports($feature) {
if (defined('FEATURE_MOD_PURPOSE')) {
// Only defined in M4.0+.
if ($feature === FEATURE_MOD_PURPOSE) {
return MOD_PURPOSE_COMMUNICATION;
}
}
switch($feature) { switch($feature) {
case FEATURE_GROUPS: case FEATURE_GROUPS:
return true; return true;
...@@ -54,8 +60,6 @@ function pdfannotator_supports($feature) { ...@@ -54,8 +60,6 @@ function pdfannotator_supports($feature) {
return true; return true;
case FEATURE_COMMENT: case FEATURE_COMMENT:
return true; return true;
case FEATURE_MOD_PURPOSE:
return MOD_PURPOSE_COMMUNICATION;
default: default:
return null; return null;
} }
......
...@@ -25,7 +25,7 @@ ...@@ -25,7 +25,7 @@
defined('MOODLE_INTERNAL') || die(); defined('MOODLE_INTERNAL') || die();
$plugin->component = 'mod_pdfannotator'; $plugin->component = 'mod_pdfannotator';
$plugin->version = 2023033000; $plugin->version = 2023040400;
$plugin->release = 'PDF Annotator v1.5 release 3'; $plugin->release = 'PDF Annotator v1.5 release 3';
$plugin->requires = 2021051700; $plugin->requires = 2021051700;
$plugin->maturity = MATURITY_STABLE; $plugin->maturity = MATURITY_STABLE;
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment