Details

    • Type: Sub-task
    • Status: Closed
    • Priority: Minor
    • Resolution: Implemented
    • Affects Version/s: Trunk
    • Fix Version/s: Upcoming Release
    • Component/s: framework
    • Labels:
      None

      Description

      • PreferenceWorker.java:90, RpC_REPEATED_CONDITIONAL_TEST
        RpC: Repeated conditional test in org.apache.ofbiz.common.preferences.PreferenceWorker.checkCopyPermission(DispatchContext, Map)

      The code contains a conditional test is performed twice, one right after the other (e.g., x == 0 || x == 0). Perhaps the second occurrence is intended to be something else (e.g., x == 0 || y == 0).

      • PreferenceWorker.java:90, RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE
        RCN: Redundant nullcheck of userLoginIdArg, which is known to be non-null in org.apache.ofbiz.common.preferences.PreferenceWorker.checkCopyPermission(DispatchContext, Map)

      This method contains a redundant check of a known non-null value against the constant null.

        Activity

        Hide
        Dennis Balkir Dennis Balkir added a comment - - edited
        • Diamond Operators fixed
        • Line 90: removed userLoginIdArg != null &&, because it was unnecessary
        Show
        Dennis Balkir Dennis Balkir added a comment - - edited Diamond Operators fixed Line 90: removed userLoginIdArg != null && , because it was unnecessary
        Hide
        mbrohl Michael Brohl added a comment -

        Thanks Dennis,

        your patch is in trunk r1811433.

        Show
        mbrohl Michael Brohl added a comment - Thanks Dennis, your patch is in trunk r1811433.

          People

          • Assignee:
            mbrohl Michael Brohl
            Reporter:
            Dennis Balkir Dennis Balkir
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development