instacart/redux-rails

View on GitHub

Showing 45 of 45 total issues

Avoid too many return statements within this function.
Open

            return null
Severity: Major
Found in src/apiReducer.js - About 30 mins to fix

    Avoid too many return statements within this function.
    Open

              return {
                ...state,
                ...{ models: setMemberLoading({idAttribute, id, cId, state}) }
              }
    Severity: Major
    Found in src/apiReducer.js - About 30 mins to fix

      Avoid too many return statements within this function.
      Open

                  return {
                    ...state,
                    ...{ models: destroyTempMemeber({cId, state}) }
                  }
      Severity: Major
      Found in src/apiReducer.js - About 30 mins to fix

        Avoid too many return statements within this function.
        Open

                    return {
                      ...state,
                      ...{
                        loading: true,
                        loadingError: undefined
        Severity: Major
        Found in src/apiReducer.js - About 30 mins to fix

          Avoid too many return statements within this function.
          Open

                    return {
                      ...state,
                      ...createNewCollection({
                        models: setMemberAttributes({id, data, state,
                          metaData: { loading: false, ...metaData }
          Severity: Major
          Found in src/apiReducer.js - About 30 mins to fix

            Avoid too many return statements within this function.
            Open

                        return createNewModel({
                          metaData: { loading: true, queryParams },
                          attributes: state.attributes
                        })
            Severity: Major
            Found in src/apiReducer.js - About 30 mins to fix

              Avoid too many return statements within this function.
              Open

                return true
              Severity: Major
              Found in src/utilities.js - About 30 mins to fix

                Avoid too many return statements within this function.
                Open

                            return createNewModel({id, metaData,
                              attributes: { ...state.attributes, ...data }
                            })
                Severity: Major
                Found in src/apiReducer.js - About 30 mins to fix

                  Avoid too many return statements within this function.
                  Open

                            return {
                              ...state,
                              ...{ models: setMemberLoadingError({state, id, error}) }
                            }
                  Severity: Major
                  Found in src/apiReducer.js - About 30 mins to fix

                    Avoid too many return statements within this function.
                    Open

                              return createNewCollection({
                                models: setMemberAttributes({cId, state})
                              })
                    Severity: Major
                    Found in src/apiReducer.js - About 30 mins to fix

                      Avoid too many return statements within this function.
                      Open

                                  return createNewModel({id,
                                    metaData: { loading: true, __prevData},
                                    attributes: state.attributes
                                  })
                      Severity: Major
                      Found in src/apiReducer.js - About 30 mins to fix

                        Avoid too many return statements within this function.
                        Open

                                  return {
                                    ...state,
                                    ...{ models: setMemberLoading({id, state}) }
                                  }
                        Severity: Major
                        Found in src/apiReducer.js - About 30 mins to fix

                          Avoid too many return statements within this function.
                          Open

                                      return createNewModel({id,
                                        attributes: { ...state.attributes, ...data },
                                        metaData
                                      })
                          Severity: Major
                          Found in src/apiReducer.js - About 30 mins to fix

                            Avoid too many return statements within this function.
                            Open

                                      return {
                                        ...state,
                                        ...{ models: setMemberLoadingError({state, id, error}) }
                                      }
                            Severity: Major
                            Found in src/apiReducer.js - About 30 mins to fix

                              Avoid too many return statements within this function.
                              Open

                                        if (destroy && isSingleModel) { return null }
                              Severity: Major
                              Found in src/apiReducer.js - About 30 mins to fix

                                Avoid too many return statements within this function.
                                Open

                                            return createNewModel({cId})
                                Severity: Major
                                Found in src/apiReducer.js - About 30 mins to fix

                                  Avoid too many return statements within this function.
                                  Open

                                              return createNewModel({id, cId,
                                                attributes: { ...state.attributes, ...data },
                                                metaData
                                              })
                                  Severity: Major
                                  Found in src/apiReducer.js - About 30 mins to fix

                                    Avoid too many return statements within this function.
                                    Open

                                              return {
                                                ...state,
                                                ...{ models: setMemberAttributes({id, data, metaData, state, replaceAttributes: false}) }
                                              }
                                    Severity: Major
                                    Found in src/apiReducer.js - About 30 mins to fix

                                      Avoid too many return statements within this function.
                                      Open

                                                  return createNewModel({id,
                                                    attributes: state.attributes,
                                                    metaData: { loadingError: error }
                                                  })
                                      Severity: Major
                                      Found in src/apiReducer.js - About 30 mins to fix

                                        Avoid too many return statements within this function.
                                        Open

                                                    return createNewModel({id, cId,
                                                      attributes: { ...currentModel.attributes, ...data },
                                                      metaData: newMeta
                                                    })
                                        Severity: Major
                                        Found in src/apiReducer.js - About 30 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language