Skip to content

Commit

Permalink
MDL-11608 Removed stripslashes_safe($rename) and changed PARAM_RAW to…
Browse files Browse the repository at this point in the history
… PARAM_TEXT for rename param
  • Loading branch information
nicolasconnault committed Oct 10, 2007
1 parent e1be60d commit 1ffd2c0
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions course/category.php
Expand Up @@ -15,7 +15,7 @@
$moveup = optional_param('moveup', 0, PARAM_INT);
$movedown = optional_param('movedown', 0, PARAM_INT);
$moveto = optional_param('moveto', 0, PARAM_INT);
$rename = optional_param('rename', '', PARAM_RAW);
$rename = optional_param('rename', '', PARAM_TEXT);
$resort = optional_param('resort', 0, PARAM_BOOL);
$addsubcategory=optional_param('addsubcategory', '', PARAM_NOTAGS);

Expand Down Expand Up @@ -66,7 +66,7 @@
if (has_capability('moodle/category:update', $context)) {
/// Rename the category if requested
if (!empty($rename) and confirm_sesskey()) {
$category->name = stripslashes_safe($rename);
$category->name = $rename;
if (! set_field("course_categories", "name", $category->name, "id", $category->id)) {
notify("An error occurred while renaming the category");
}
Expand Down

0 comments on commit 1ffd2c0

Please sign in to comment.