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

Remove dead code from profile_field_textarea

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.2.2
    • Fix Version/s: 2.4
    • Component/s: Other
    • Labels:

      Description

      edit_field_add method in profile_field_textarea declares $cols & $rows:

      $cols = $this->field->param1;
      $rows = $this->field->param2;

      but those are never used. They are also not set anywhere - there is no option in UI for custom profile textarea field to set number of columns and rows.
      I think that this is not really necessary to have cols & rows settable - so let's remove that dead code.

        Gliffy Diagrams

          Attachments

            Activity

            Hide
            salvetore Michael de Raadt added a comment -

            Thanks for spotting that.

            Show
            salvetore Michael de Raadt added a comment - Thanks for spotting that.
            Hide
            rwijaya Rossiani Wijaya added a comment -

            Hi Tomasz,

            Thank you for reporting and providing the solution.

            I added patch for 2.2 and 2.3 branches.

            Sending for peer review.

            Show
            rwijaya Rossiani Wijaya added a comment - Hi Tomasz, Thank you for reporting and providing the solution. I added patch for 2.2 and 2.3 branches. Sending for peer review.
            Hide
            rwijaya Rossiani Wijaya added a comment -

            Rebasing Tomasz patch.

            Show
            rwijaya Rossiani Wijaya added a comment - Rebasing Tomasz patch.
            Hide
            ankit_frenz Ankit Agarwal added a comment -

            Hi guys,
            Patch looks good to me.
            +1 for integration
            Thanks

            Show
            ankit_frenz Ankit Agarwal added a comment - Hi guys, Patch looks good to me. +1 for integration Thanks
            Hide
            rwijaya Rossiani Wijaya added a comment -

            Thanks Ankit for reviewing.

            Submitting for integration review.

            Show
            rwijaya Rossiani Wijaya added a comment - Thanks Ankit for reviewing. Submitting for integration review.
            Hide
            poltawski Dan Poltawski added a comment -

            Thanks guys.

            As this is an improvement and shouldn't have any visible effect I integrated to master only. Its not worth making changes on stable branches for this.

            Show
            poltawski Dan Poltawski added a comment - Thanks guys. As this is an improvement and shouldn't have any visible effect I integrated to master only. Its not worth making changes on stable branches for this.
            Hide
            markn Mark Nelson added a comment -

            Was able to create a text area with no issues. Passed.

            Show
            markn Mark Nelson added a comment - Was able to create a text area with no issues. Passed.
            Hide
            nebgor Aparup Banerjee added a comment -

            Your issue has dug up some gold.
            It works great i've been told.
            Go forth, be brave, be bold.

            yay! "All your thoughts are belong to everyone."

            Thanks and ciao!

            Show
            nebgor Aparup Banerjee added a comment - Your issue has dug up some gold. It works great i've been told. Go forth, be brave, be bold. yay! "All your thoughts are belong to everyone." Thanks and ciao!

              People

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

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Fix Release Date:
                  3/Dec/12