Showing 90 of 251 total issues

Avoid too many return statements within this function.
Open

      return flow([
        set(['filter', 'text'], ''),
        set(['filter', 'tags'], []),
        set(['filter', 'language'], ''),
        set(['filter', 'status'], action.payload.status),
Severity: Major
Found in src/reducers/snippets.js - About 30 mins to fix

    Avoid too many return statements within this function.
    Open

          return set(['comments', action.meta.id], action.payload, state);
    Severity: Major
    Found in src/reducers/snippets.js - About 30 mins to fix

      Avoid too many return statements within this function.
      Open

          return filter({ truncated: true }, sortedSnippets);
      Severity: Major
      Found in src/utils/snippets.ts - About 30 mins to fix

        Avoid too many return statements within this function.
        Open

              return 'untagged';
        Severity: Major
        Found in src/components/layout/sidebar/Sidebar.js - About 30 mins to fix

          Avoid too many return statements within this function.
          Open

                return set(['edit', 'files', action.payload.uuid, 'delete'], true, state);
          Severity: Major
          Found in src/reducers/snippets.js - About 30 mins to fix

            Avoid too many return statements within this function.
            Open

                  return set(['comments', action.meta.id], [], state);
            Severity: Major
            Found in src/reducers/snippets.js - About 30 mins to fix

              Avoid too many return statements within this function.
              Open

                return sortedSnippets;
              Severity: Major
              Found in src/utils/snippets.ts - About 30 mins to fix

                Avoid too many return statements within this function.
                Open

                      return set(
                        ['snippets', action.payload.id],
                        snippetStructure(action.payload, state.starred),
                        state
                      );
                Severity: Major
                Found in src/reducers/snippets.js - About 30 mins to fix

                  Avoid too many return statements within this function.
                  Open

                        return set('edit', {}, state);
                  Severity: Major
                  Found in src/reducers/snippets.js - About 30 mins to fix

                    Avoid too many return statements within this function.
                    Open

                            return set(['settings', action.payload.key], result, state);
                    Severity: Major
                    Found in src/reducers/ui.js - About 30 mins to fix

                      Avoid too many return statements within this function.
                      Open

                            return flow([
                              set(['edit', 'description'], description),
                              set(['edit', 'files'], keyBy('uuid', preparedFiles))
                            ])(state);
                      Severity: Major
                      Found in src/reducers/snippets.js - About 30 mins to fix

                        Avoid too many return statements within this function.
                        Open

                              return set(['settings', action.payload.key], action.payload.value, state);
                        Severity: Major
                        Found in src/reducers/ui.js - About 30 mins to fix

                          Avoid too many return statements within this function.
                          Open

                                return flow([set('rateLimit', action.payload), set(['rateLimit', 'loading'], false)])(state);
                          Severity: Major
                          Found in src/reducers/ui.js - About 30 mins to fix

                            Avoid too many return statements within this function.
                            Open

                                    return flow([
                                      set(['settings', action.payload.key], action.payload.value),
                                      set(['settings', 'theme', 'baseAppColor'], action.payload.value),
                                      set(
                                        ['settings', 'theme', 'headerBgLightest'],
                            Severity: Major
                            Found in src/reducers/ui.js - About 30 mins to fix

                              Avoid too many return statements within this function.
                              Open

                                return snippets;
                              Severity: Major
                              Found in src/utils/snippets.ts - About 30 mins to fix

                                Avoid too many return statements within this function.
                                Open

                                      return set(['edit', 'files'], merge(newFile, existingFiles || {}), state);
                                Severity: Major
                                Found in src/reducers/snippets.js - About 30 mins to fix

                                  Avoid too many return statements within this function.
                                  Open

                                      return filter((snippet) => snippet.tags === null || size(snippet.tags) === 0, sortedSnippets);
                                  Severity: Major
                                  Found in src/utils/snippets.ts - About 30 mins to fix

                                    Avoid too many return statements within this function.
                                    Open

                                          return state;
                                    Severity: Major
                                    Found in src/reducers/login.js - About 30 mins to fix

                                      Avoid too many return statements within this function.
                                      Open

                                            return 'large files';
                                      Severity: Major
                                      Found in src/components/layout/sidebar/Sidebar.js - About 30 mins to fix

                                        Avoid too many return statements within this function.
                                        Open

                                              return state;
                                        Severity: Major
                                        Found in src/reducers/snippets.js - About 30 mins to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language