WikiEducationFoundation/WikiEduDashboard

View on GitHub
app/assets/javascripts/reducers/instructor_alert.js

Summary

Maintainability
A
1 hr
Test Coverage
F
40%

Function reducer has 32 lines of code (exceeds 25 allowed). Consider refactoring.
Open

const reducer = (state = initialState, action) => {
  switch (action.type) {
    case ALERT_INSTRUCTOR_UPDATE_MESSAGE:
      return {
        ...state,
Severity: Minor
Found in app/assets/javascripts/reducers/instructor_alert.js - About 1 hr to fix

    Parsing error: Cannot find module 'babel-plugin-root-import' Require stack: - /usr/local/node_modules/@babel/core/lib/config/files/plugins.js - /usr/local/node_modules/@babel/core/lib/config/files/index.js - /usr/local/node_modules/@babel/core/lib/index.js - /usr/local/node_modules/@babel/eslint-parser/lib/worker/babel-core.cjs - /usr/local/node_modules/@babel/eslint-parser/lib/worker/handle-message.cjs - /usr/local/node_modules/@babel/eslint-parser/lib/client.cjs - /usr/local/node_modules/@babel/eslint-parser/lib/index.cjs - /usr/local/node_modules/eslint/lib/cli-engine/config-array-factory.js - /usr/src/app/lib/eslint6-patch.js - /usr/src/app/lib/eslint.js - /usr/src/app/bin/eslint.js
    Open

    import { ALERT_INSTRUCTOR_CREATE, ALERT_INSTRUCTOR_FAILED, ALERT_INSTRUCTOR_MODAL_VISIBLE, ALERT_INSTRUCTOR_MODAL_HIDDEN, ALERT_INSTRUCTOR_UPDATE_MESSAGE, ALERT_INSTRUCTOR_UPDATE_SUBJECT } from '../constants/alert';

    For more information visit Source: http://eslint.org/docs/rules/

    There are no issues that match your filters.

    Category
    Status