Moodle
  1. Moodle
  2. MDL-17741

typo in /admin/xmldb/actions/edit_field/edit_field.class.php (patch attached)

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.8.7
    • Fix Version/s: 1.8.8, 1.9.4
    • Component/s: Administration
    • Labels:
      None
    • Difficulty:
      Easy
    • Affected Branches:
      MOODLE_18_STABLE
    • Fixed Branches:
      MOODLE_18_STABLE, MOODLE_19_STABLE

      Description

      I happened to come across a typo in /admin/xmldb/actions/edit_field/edit_field.class.php (see attached patch).

        Gliffy Diagrams

        1. edit_field.class.diff
          0.9 kB
          Anthony Borrow
        2. MDL-17741.diff
          3 kB
          Anthony Borrow

          Activity

          Hide
          Anthony Borrow added a comment -

          Eloy - When I fix something simple like this I'm using Eclipse. I tend to get merging and tagging mixed up. What is the final step I need to do to make sure that this does not wind up on the unmerged list. It is about time I get this down. Thanks for your guidance. Peace - Anthony

          Show
          Anthony Borrow added a comment - Eloy - When I fix something simple like this I'm using Eclipse. I tend to get merging and tagging mixed up. What is the final step I need to do to make sure that this does not wind up on the unmerged list. It is about time I get this down. Thanks for your guidance. Peace - Anthony
          Hide
          Anthony Borrow added a comment -

          Eloy - I think I merged this correctly, if you could look and let me know I would appreciate it. I was able to do it from the command line. I am assuming there is a way to do it through Eclipse. I simply used: cvs tag -RF MOODLE_19_MERGED edit_field.class.php. Peace - Anthony

          Show
          Anthony Borrow added a comment - Eloy - I think I merged this correctly, if you could look and let me know I would appreciate it. I was able to do it from the command line. I am assuming there is a way to do it through Eclipse. I simply used: cvs tag -RF MOODLE_19_MERGED edit_field.class.php. Peace - Anthony
          Hide
          Anthony Borrow added a comment -

          Eloy - I noticed that there were other typos here that Eclipse alerted me to. Also, I believe that $rec should ideally be initialized as an array which prevents an Eclipse warning in /admin/xmldb/actions/test/test.class.php. The attached diff corrects the $tableparam typos and initializes $rec.These are trivial fixes but I figured I would at least document them. If you want me to check them in, just assign this to me otherwise I'll leave it in your hands. Peace - Anthony

          Show
          Anthony Borrow added a comment - Eloy - I noticed that there were other typos here that Eclipse alerted me to. Also, I believe that $rec should ideally be initialized as an array which prevents an Eclipse warning in /admin/xmldb/actions/test/test.class.php. The attached diff corrects the $tableparam typos and initializes $rec.These are trivial fixes but I figured I would at least document them. If you want me to check them in, just assign this to me otherwise I'll leave it in your hands. Peace - Anthony
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Yup, Anthony,

          the way to move the merged tag is, as you say:

          cvs tag -RF TAG_NAME files to tag

          so, as you've committed the fix for 18_STABLE and 19_STABLE (and HEAD), you need to do:

          cvs tag -RF MOODLE_18_MERGED edit_field.class.php (in the 18_STABLE branch) and

          cvs tag -RF MOODLE_19_MERGED edit_field.class.php (in the 19_STABLE branch)

          to have both MERGED tags properly moved to the last version in each branch.

          (Minor note: I think the "R" option is for "recursive". I don't use it really, because one mistake can cause ALL files to be wrongly merged. Just one comment).

          About the other typos, yup, the "$tableparm" is Ok... but the "$rec"... it's an object and not an array, if I'm not wrong. Feel free to commit and merge. Assigning to you! Thanks!

          Show
          Eloy Lafuente (stronk7) added a comment - Yup, Anthony, the way to move the merged tag is, as you say: cvs tag -RF TAG_NAME files to tag so, as you've committed the fix for 18_STABLE and 19_STABLE (and HEAD), you need to do: cvs tag -RF MOODLE_18_MERGED edit_field.class.php (in the 18_STABLE branch) and cvs tag -RF MOODLE_19_MERGED edit_field.class.php (in the 19_STABLE branch) to have both MERGED tags properly moved to the last version in each branch. (Minor note: I think the "R" option is for "recursive". I don't use it really, because one mistake can cause ALL files to be wrongly merged. Just one comment). About the other typos, yup, the "$tableparm" is Ok... but the "$rec"... it's an object and not an array, if I'm not wrong. Feel free to commit and merge. Assigning to you! Thanks!
          Hide
          Anthony Borrow added a comment -

          Eloy - Thanks. Yep, the $rec was just an object (not an array) so I left that alone. I did use the patch and fixed up the other typos. Petr had caught the last one in HEAD but everything should be fixed up and merged. I'm sure there is a way to do this in Eclipse but I'll leave that for another day. Peace - Anthony

          Show
          Anthony Borrow added a comment - Eloy - Thanks. Yep, the $rec was just an object (not an array) so I left that alone. I did use the patch and fixed up the other typos. Petr had caught the last one in HEAD but everything should be fixed up and merged. I'm sure there is a way to do this in Eclipse but I'll leave that for another day. Peace - Anthony
          Hide
          Eloy Lafuente (stronk7) added a comment -

          Reviewed. Tag moved properly too. Closing. Thanks!

          Show
          Eloy Lafuente (stronk7) added a comment - Reviewed. Tag moved properly too. Closing. Thanks!
          Hide
          Anthony Borrow added a comment -

          Eloy - Thanks for the review, now that I have tagging down my gang member friends will be so proud of me. Peace - Anthony

          Show
          Anthony Borrow added a comment - Eloy - Thanks for the review, now that I have tagging down my gang member friends will be so proud of me. Peace - Anthony
          Hide
          Daniele Cordella added a comment -

          God bless you both.
          By reading this conversation I not only get info about HowTo in moodle/cvs/patch/merge/bla/bla/bla but I also get a working style that is what we all should learn. Thank you. Ciao and happy holidays.

          Show
          Daniele Cordella added a comment - God bless you both. By reading this conversation I not only get info about HowTo in moodle/cvs/patch/merge/bla/bla/bla but I also get a working style that is what we all should learn. Thank you. Ciao and happy holidays.

            People

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

              Dates

              • Created:
                Updated:
                Resolved: