abarmenkov/frontend-project-lvl2

View on GitHub
src/formDiff.js

Summary

Maintainability
A
1 hr
Test Coverage
A
100%

Function getDiff has 35 lines of code (exceeds 25 allowed). Consider refactoring.
Open

const getDiff = (data1, data2) => {
  const keys = getKeys(data1, data2);
  return keys
    .map((key) => {
      if (_.isObject(data1[key]) && _.isObject(data2[key])) {
Severity: Minor
Found in src/formDiff.js - About 1 hr to fix

    Avoid too many return statements within this function.
    Open

          return { type: 'unchanged', key, value: data1[key] };
    Severity: Major
    Found in src/formDiff.js - About 30 mins to fix

      There are no issues that match your filters.

      Category
      Status