Details

    • Type: Sub-task Sub-task
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 2.5
    • Fix Version/s: 2.6
    • Component/s: Badges
    • Labels:
    • Rank:
      50775

      Description

      Did you remember to call setType() for 'grade_14'? Defaulting to PARAM_RAW cleaning.

      line 1303 of /lib/formslib.php: call to debugging()
      line 281 of /lib/formslib.php: call to moodleform->detectMissingSetType()
      line 202 of /lib/formslib.php: call to moodleform->_process_submission()
      line 78 of /badges/criteria_settings.php: call to moodleform->moodleform()

      To replicate:

      1. add a new badge
      2. add badge criteria for completing a set of course

        Activity

        Hide
        Ankit Agarwal added a comment -

        Hi Yuliya,
        The patch looks nice. I did notice a few usages in helper_search_form() without setTypes, but since that api is just used to generate html code and is not really used in a "moodle form" sense, am happy to go ahead with the patch.
        Feel free to push for integration.
        cheers

        Show
        Ankit Agarwal added a comment - Hi Yuliya, The patch looks nice. I did notice a few usages in helper_search_form() without setTypes, but since that api is just used to generate html code and is not really used in a "moodle form" sense, am happy to go ahead with the patch. Feel free to push for integration. cheers
        Hide
        Sam Hemelryk added a comment -

        Thanks Yuliya, I've cherry-picked the commit and integrated it now.
        I cherry-picked as the branch contained other commits. Please msg here is that assumption was wrong and we can look to rectify it.

        Many thanks
        Sam

        Show
        Sam Hemelryk added a comment - Thanks Yuliya, I've cherry-picked the commit and integrated it now. I cherry-picked as the branch contained other commits. Please msg here is that assumption was wrong and we can look to rectify it. Many thanks Sam
        Hide
        Yuliya Bozhko added a comment -

        Thanks! I am pretty sure it was 2.5 master branch before the release last week. I was not sure if I needed to update it as it was already pushed for integration.

        Show
        Yuliya Bozhko added a comment - Thanks! I am pretty sure it was 2.5 master branch before the release last week. I was not sure if I needed to update it as it was already pushed for integration.
        Hide
        Dan Poltawski added a comment -

        I've cherry-picked the patch to 2.5 (e7873336223b2e9ce03a880e2cc5eb85755894c4) as Michael noticed it seemed to be missing.

        Show
        Dan Poltawski added a comment - I've cherry-picked the patch to 2.5 (e7873336223b2e9ce03a880e2cc5eb85755894c4) as Michael noticed it seemed to be missing.
        Hide
        Michael de Raadt added a comment -

        Test result: Success!

        Tested in 2.5 and master. No warnings shown.

        Show
        Michael de Raadt added a comment - Test result: Success! Tested in 2.5 and master. No warnings shown.
        Hide
        Dan Poltawski added a comment -

        Thanks for your contributions!

        _main:
        @ BB#0:
                push    {r7, lr}
                mov     r7, sp
                sub     sp, #4
                movw    r0, :lower16:(L_.str-(LPC0_0+4))
                movt    r0, :upper16:(L_.str-(LPC0_0+4))
        LPC0_0:
                add     r0, pc
                bl      _printf
                movs    r1, #0
                movt    r1, #0
                str     r0, [sp]                @ 4-byte Spill
                mov     r0, r1
                add     sp, #4
                pop     {r7, pc}
        
                .section        __TEXT,__cstring,cstring_literals
        L_.str:                                 @ @.str
                .asciz   "This code is now upstream!"
        
        Show
        Dan Poltawski added a comment - Thanks for your contributions! _main: @ BB#0: push {r7, lr} mov r7, sp sub sp, #4 movw r0, :lower16:(L_.str-(LPC0_0+4)) movt r0, :upper16:(L_.str-(LPC0_0+4)) LPC0_0: add r0, pc bl _printf movs r1, #0 movt r1, #0 str r0, [sp] @ 4- byte Spill mov r0, r1 add sp, #4 pop {r7, pc} .section __TEXT,__cstring,cstring_literals L_.str: @ @.str .asciz "This code is now upstream!"

          People

          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: