Coursemology/coursemology2

View on GitHub
client/app/bundles/course/assessment/submission/actions/submissions.js

Summary

Maintainability
C
7 hrs
Test Coverage

Function downloadSubmissions has 36 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function downloadSubmissions(type, downloadFormat) {
  const actions =
    downloadFormat === 'zip'
      ? {
          request: actionTypes.DOWNLOAD_SUBMISSIONS_FILES_REQUEST,

Function unsubmitAllSubmissions has 30 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function unsubmitAllSubmissions(type) {
  return (dispatch) => {
    dispatch({ type: actionTypes.UNSUBMIT_ALL_SUBMISSIONS_REQUEST });

    const handleSuccess = () => {

Function publishSubmissions has 28 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function publishSubmissions(type) {
  return (dispatch) => {
    dispatch({ type: actionTypes.PUBLISH_SUBMISSIONS_REQUEST });

    const handleSuccess = () => {

Function forceSubmitSubmissions has 28 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function forceSubmitSubmissions(type) {
  return (dispatch) => {
    dispatch({ type: actionTypes.FORCE_SUBMIT_SUBMISSIONS_REQUEST });

    const handleSuccess = () => {

Function deleteAllSubmissions has 28 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function deleteAllSubmissions(type) {
  return (dispatch) => {
    dispatch({ type: actionTypes.DELETE_ALL_SUBMISSIONS_REQUEST });

    const handleSuccess = () => {

Function downloadStatistics has 28 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export function downloadStatistics(type) {
  return (dispatch) => {
    dispatch({ type: actionTypes.DOWNLOAD_STATISTICS_REQUEST });

    const handleSuccess = (successData) => {

There are no issues that match your filters.

Category
Status