bookbrainz/bookbrainz-site

View on GitHub

Showing 365 of 1,033 total issues

File entity.tsx has 1110 lines of code (exceeds 250 allowed). Consider refactoring.
Open

/*
 * Copyright (C) 2016  Ben Ockmore
 *               2016  Sean Burke
 *                 2021  Akash Gupta
 * This program is free software; you can redistribute it and/or modify
Severity: Major
Found in src/server/routes/entity/entity.tsx - About 2 days to fix

    File editor.tsx has 564 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    /*
     * Copyright (C) 2015, 2020  Ben Ockmore
     *               2015-2016   Sean Burke
     *
     * This program is free software; you can redistribute it and/or modify
    Severity: Major
    Found in src/server/routes/editor.tsx - About 1 day to fix

      File edition-section.tsx has 494 lines of code (exceeds 250 allowed). Consider refactoring.
      Open

      /*
       * Copyright (C) 2016  Ben Ockmore
       *
       * This program is free software; you can redistribute it and/or modify
       * it under the terms of the GNU General Public License as published by
      Severity: Minor
      Found in src/client/entity-editor/edition-section/edition-section.tsx - About 7 hrs to fix

        File achievement.js has 481 lines of code (exceeds 250 allowed). Consider refactoring.
        Open

        /*
         * Copyright (C) 2016  Max Prettyjohns
         *
         * This program is free software; you can redistribute it and/or modify
         * it under the terms of the GNU General Public License as published by
        Severity: Minor
        Found in src/server/helpers/achievement.js - About 7 hrs to fix

          File test-data.js has 478 lines of code (exceeds 250 allowed). Consider refactoring.
          Open

          /*
           * Copyright (C) 2016  Max Prettyjohns
           *
           * This program is free software; you can redistribute it and/or modify
           * it under the terms of the GNU General Public License as published by
          Severity: Minor
          Found in data/test-data.js - About 7 hrs to fix

            File cbReviewModal.tsx has 477 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            /* eslint-disable react/no-unused-state */
            /*
             * Copyright (C) 2022       Ansh Goyal
             *
             * This program is free software; you can redistribute it and/or modify
            Severity: Minor
            Found in src/client/components/pages/entities/cbReviewModal.tsx - About 7 hrs to fix

              File edition.ts has 459 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              /*
               * Copyright (C) 2015       Ben Ockmore
               *               2015-2016  Sean Burke
               *
               * This program is free software; you can redistribute it and/or modify
              Severity: Minor
              Found in src/server/routes/entity/edition.ts - About 7 hrs to fix

                File relationship-type.tsx has 444 lines of code (exceeds 250 allowed). Consider refactoring.
                Open

                /*
                 * Copyright (C) 2023 Shivam Awasthi
                 *
                 * This program is free software; you can redistribute it and/or modify
                 * it under the terms of the GNU General Public License as published by
                Severity: Minor
                Found in src/client/components/forms/type-editor/relationship-type.tsx - About 6 hrs to fix

                  Function render has 163 lines of code (exceeds 25 allowed). Consider refactoring.
                  Open

                      render() {
                          if (this.state.collaborators.length === 0) {
                              this.handleAddCollaborator();
                          }
                  
                  
                  Severity: Major
                  Found in src/client/components/forms/userCollection.js - About 6 hrs to fix

                    Function AboutPage has 162 lines of code (exceeds 25 allowed). Consider refactoring.
                    Open

                    function AboutPage(): JSX.Element {
                        const NESLink =
                            'https://ocharles.org.uk/blog/posts/' +
                                '2012-07-10-nes-does-it-better-1.html';
                    
                    
                    Severity: Major
                    Found in src/client/components/pages/about.tsx - About 6 hrs to fix

                      File relationship-editor.tsx has 425 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      /*
                       * Copyright (C) 2018  Ben Ockmore
                       *                 2021  Akash Gupta
                       * This program is free software; you can redistribute it and/or modify
                       * it under the terms of the GNU General Public License as published by
                      Severity: Minor
                      Found in src/client/entity-editor/relationship-editor/relationship-editor.tsx - About 6 hrs to fix

                        File eslint.config.js has 414 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        /* eslint-disable comma-dangle */
                        /* eslint-disable quotes */
                        import pluginImport from 'eslint-plugin-import';
                        import pluginNode from 'eslint-plugin-node';
                        import pluginReact from 'eslint-plugin-react';
                        Severity: Minor
                        Found in eslint.config.js - About 5 hrs to fix

                          Function renderLoggedInDropdown has 147 lines of code (exceeds 25 allowed). Consider refactoring.
                          Open

                              renderLoggedInDropdown() {
                                  const {user} = this.props;
                          
                                  const createDropdownTitle = (
                                      <span>
                          Severity: Major
                          Found in src/client/containers/layout.js - About 5 hrs to fix

                            Function renderHeader has 144 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                                renderHeader() {
                                    return (
                                        <div>
                                            <Alert className="text-center" variant="warning">
                                                Under development — adventurous users, please test and
                            Severity: Major
                            Found in src/client/components/pages/index.js - About 5 hrs to fix

                              Function render has 141 lines of code (exceeds 25 allowed). Consider refactoring.
                              Open

                                  render() {
                                      const {showLastModified, showOwner, showIfOwnerOrCollaborator, showPrivacy, results, tableHeading, user, ownerId} = this.props;
                                      const entityTypeSelect = (
                                          <DropdownButton
                                              className="margin-bottom-d5"
                              Severity: Major
                              Found in src/client/components/pages/parts/collections-table.js - About 5 hrs to fix

                                File layout.js has 399 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                /*
                                 * Copyright (C) 2018  Theodore Fabian Rudy
                                 *                  2016  Daniel Hsing
                                 *                  2016  Ben Ockmore
                                 *                  2016  Sean Burke
                                Severity: Minor
                                Found in src/client/containers/layout.js - About 5 hrs to fix

                                  File entity.js has 394 lines of code (exceeds 250 allowed). Consider refactoring.
                                  Open

                                  /*
                                   * Copyright (C) 2016  Ben Ockmore
                                   *
                                   * This program is free software; you can redistribute it and/or modify
                                   * it under the terms of the GNU General Public License as published by
                                  Severity: Minor
                                  Found in src/server/helpers/diffFormatters/entity.js - About 5 hrs to fix

                                    Function processMergeOperation has 135 lines of code (exceeds 25 allowed). Consider refactoring.
                                    Open

                                    export async function processMergeOperation(orm, transacting, session, mainEntity, allEntities, relationshipSets) {
                                        const {Edition, bookshelf} = orm;
                                        const {mergingEntities} = session.mergeQueue;
                                        if (!mergingEntities) {
                                            throw new Error('Merge handler called with no merge queue, aborting');
                                    Severity: Major
                                    Found in src/server/routes/entity/entity.tsx - About 5 hrs to fix

                                      Function render has 133 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                          render() {
                                              let messageComponent = null;
                                              if (this.state.message.text) {
                                                  messageComponent = (
                                                      <div>
                                      Severity: Major
                                      Found in src/client/components/pages/parts/add-to-collection-modal.js - About 5 hrs to fix

                                        Function render has 132 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                            render() {
                                                const noResults = !this.props.results || this.props.results.length === 0;
                                        
                                                const results = this.props.results.map((result) => {
                                                    if (!result) {
                                        Severity: Major
                                        Found in src/client/components/pages/parts/search-results.js - About 5 hrs to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language