Skip to content

Commit

Permalink
refactor(plugin): php mess detector violations
Browse files Browse the repository at this point in the history
Solved:

* Avoid unused parameters
* Avoid unused local variables

#taskid: 19424
  • Loading branch information
dcanet-at-wiris committed Jan 18, 2022
1 parent a43291e commit a35b880
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions lib.php
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,8 @@
class tinymce_tiny_mce_wiris extends editor_tinymce_plugin {
protected $buttons = array('tiny_mce_wiris_formulaEditor', 'tiny_mce_wiris_CAS');

protected function update_init_params(array &$params, context $context,
array $options = null) {
global $PAGE, $CFG, $COURSE;
protected function update_init_params(array &$params, context $context) {
global $PAGE, $COURSE;
// We need to know if MathType filter are active in the context of the course.
// If not MathTYPe filter should be disabled.

Expand Down Expand Up @@ -68,10 +67,10 @@ protected function update_init_params(array &$params, context $context,

// Add button after emoticon button in advancedbuttons3.
if ($editorisactive) {
$added = $this->add_button_after($params, 3, 'tiny_mce_wiris_formulaEditor', '', false);
$this->add_button_after($params, 3, 'tiny_mce_wiris_formulaEditor', '', false);
}
if ($chemistryisactive) {
$added = $this->add_button_after($params, 3, 'tiny_mce_wiris_formulaEditorChemistry', '', false);
$this->add_button_after($params, 3, 'tiny_mce_wiris_formulaEditorChemistry', '', false);
}
// Add JS file using 'plugin.min.js' instead of default name.
$this->add_js_plugin($params);
Expand Down

0 comments on commit a35b880

Please sign in to comment.