Uploaded image for project: 'CiviCRM'
  1. CiviCRM
  2. CRM-20156

Code cleanup - Do not pass $names as ref for OptionGroup::lookupValues

    Details

    • Type: Improvement
    • Status: Done/Fixed
    • Priority: Trivial
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.7.17
    • Fix Version/s: 4.7.17
    • Component/s: None
    • Labels:
      None
    • Versioning Impact:
      Patch (backwards-compatible bug fixes)
    • Documentation Required?:
      None
    • Funding Source:
      Contributed Code
    • Verified?:
      No

      Description

      This is a minor cleanup. The principle is that we should avoid passing by reference unless there is a clear expectation. In this signature $names is never altered so should not be passed by reference

      public static function lookupValues(&$params, &$names, $flip = FALSE) {

        Attachments

          Activity

            People

            • Assignee:
              eileen Eileen McNaughton
              Reporter:
              eileen Eileen McNaughton
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: