Uploaded image for project: 'Moodle'
  1. Moodle
  2. MDL-70910

core_contentbank\external\rename_content is not using validated parameters

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.9.4, 3.10.1, 3.11, 4.0
    • Fix Version/s: 3.9.5, 3.10.2
    • Component/s: Content bank
    • Labels:
    • Testing Instructions:
      Hide
      1. Go to Site Administration/Server/Tasks/Scheduled tasks
      2. Find the task "Download available H5P content types from h5p.org" and click on "Run now"
      3. Click "Run now" on the Confirm message
      4. When Process is done click on the "Content bank" icon on the left navigation drawer.
      5. Click on "Add" action button and select for example "Summary"
      6. Set the Title as "Cool bananas", and click Save.
      7. Click on the cog icon and select "Rename"
      8. Set Content name to "Frozen oranges" and click "Rename".
      9. You should see the message "The content has been renamed." and see that the name has been changed to "Frozen oranges".
      Show
      Go to Site Administration/Server/Tasks/Scheduled tasks Find the task "Download available H5P content types from h5p.org" and click on "Run now" Click "Run now" on the Confirm message When Process is done click on the "Content bank" icon on the left navigation drawer. Click on "Add" action button and select for example "Summary" Set the Title as "Cool bananas", and click Save. Click on the cog icon and select "Rename" Set Content name to "Frozen oranges" and click "Rename". You should see the message "The content has been renamed." and see that the name has been changed to "Frozen oranges".
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_310_STABLE, MOODLE_311_STABLE, MOODLE_39_STABLE, MOODLE_400_STABLE
    • Fixed Branches:
      MOODLE_310_STABLE, MOODLE_39_STABLE
    • Pull from Repository:
    • Pull 3.9 Branch:
    • Pull 3.10 Branch:
      MDL-70910-310
    • Pull 3.11 Branch:
      MDL-70910-311
    • Pull Master Branch:
      MDL-70910-master

      Description

      core_contentbank\external\rename_content execute method is using $contentid instead $params['contentid'] in some cases. For instance, here.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              davidmatamoros David Matamoros
              Reporter:
              sarjona Sara Arjona (@sarjona)
              Peer reviewer:
              Paul Holden Paul Holden
              Integrator:
              Eloy Lafuente (stronk7) Eloy Lafuente (stronk7)
              Tester:
              Anna Carissa Sadia Anna Carissa Sadia
              Participants:
              Component watchers:
              Amaia Anabitarte, Carlos Escobedo, Ferran Recio, Ilya Tregubov, Sara Arjona (@sarjona)
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:
                Fix Release Date:
                8/Mar/21

                  Time Tracking

                  Estimated:
                  Original Estimate - 0 minutes
                  0m
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 hour, 5 minutes
                  1h 5m