18F/cg-dashboard

View on GitHub

Showing 107 of 108 total issues

Function handleAction has 39 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  handleAction(action) {
    switch (action.type) {
      case serviceActionTypes.SERVICE_BINDINGS_FETCH: {
        this.isFetching = true;
        this.emitChange();
Severity: Minor
Found in static_src/stores/service_binding_store.js - About 1 hr to fix

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

      render() {
        const {
          flag,
          text,
          linkText,
    Severity: Minor
    Found in static_src/components/header/disclaimer.js - About 1 hr to fix

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

        render() {
          const { style } = this.props;
      
          if (!this.props.active || this.state.waitTimer) return null;
      
      
      Severity: Minor
      Found in static_src/components/loading.jsx - About 1 hr to fix

        Function stateSetter has 37 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

        function stateSetter() {
          const currentOrgGuid = OrgStore.currentOrgGuid;
          const currentSpaceGuid = SpaceStore.currentSpaceGuid;
          const currentSpaceName = SpaceStore.currentSpaceName;
          const currentAppGuid = AppStore.currentAppGuid;
        Severity: Minor
        Found in static_src/components/service_instance_panel.jsx - About 1 hr to fix

          Function Header has 37 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

          const Header = () => {
            const loginLink = LoginStore.isLoggedIn() ? (
              <HeaderLink>
                <Action href="/logout" label="Log out" type="outline">
                  Log out
          Severity: Minor
          Found in static_src/components/header/header.js - About 1 hr to fix

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

              render() {
                const { name, value, app, updateError, deleteError, onUpdate } = this.props;
                const { editing, deleting } = this.state;
                const { updating } = app;
            
            
            Severity: Minor
            Found in static_src/components/env/env_var_list_item.js - About 1 hr to fix

              Function handleAction has 37 lines of code (exceeds 25 allowed). Consider refactoring.
              Open

                handleAction(action) {
                  switch (action.type) {
                    case formActionTypes.FORM_FIELD_CHANGE: {
                      // Update the form field value
                      const form = this.get(action.formGuid);
              Severity: Minor
              Found in static_src/stores/form_store.js - About 1 hr to fix

                Function mapStoreToState has 37 lines of code (exceeds 25 allowed). Consider refactoring.
                Open

                function mapStoreToState() {
                  let route;
                  const { currentAppGuid } = AppStore;
                  const app = AppStore.get(currentAppGuid);
                  const envRequest = EnvStore.getEnvRequest(currentAppGuid);
                Severity: Minor
                Found in static_src/components/app_container.jsx - About 1 hr to fix

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

                    render() {
                      let actionElements;
                  
                      if (this.props.actions.length) {
                        actionElements = this.props.actions.map((action, i) => (
                  Severity: Minor
                  Found in static_src/components/notification.jsx - About 1 hr to fix

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

                      render() {
                        const stateClass = `stat-${this.props.statState}`;
                        let primaryStat = (
                          <span className="stat-primary">
                            {formatBytes(this.state.primaryStat)}
                    Severity: Minor
                    Found in static_src/components/stat.jsx - About 1 hr to fix

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

                        render() {
                          const props = this.props;
                          const expand = !!(props.org.quicklook && props.org.quicklook.open);
                      
                          return (
                      Severity: Minor
                      Found in static_src/components/org_quicklook.jsx - About 1 hr to fix

                        Function stateSetter has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                        Open

                        function stateSetter() {
                          const appGuid = AppStore.currentAppGuid;
                          const orgGuid = OrgStore.currentOrgGuid;
                          const spaceGuid = SpaceStore.currentSpaceGuid;
                        
                        
                        Severity: Minor
                        Found in static_src/components/routes_panel.jsx - About 1 hr to fix

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

                            render() {
                              const loading = <Loading text="Loading apps" />;
                              let content = <div>{loading}</div>;
                              const title = (
                                <span>
                          Severity: Minor
                          Found in static_src/components/app_list.jsx - About 1 hr to fix

                            Function handleAction has 35 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                              handleAction(action) {
                                switch (action.type) {
                                  case serviceActionTypes.SERVICE_PLAN_FETCH: {
                                    const servicePlan = this.get(action.servicePlanGuid) || {};
                                    const servicePlanFetching = Object.assign({}, servicePlan, {
                            Severity: Minor
                            Found in static_src/stores/service_plan_store.js - About 1 hr to fix

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

                                render() {
                                  const plans = sortPlansByCost(this.props.plans);
                                  let content = <div />;
                              
                                  if (empty(plans)) {
                              Severity: Minor
                              Found in static_src/components/service_plan_list.jsx - About 1 hr to fix

                                Function parseLogItem has 34 lines of code (exceeds 25 allowed). Consider refactoring.
                                Open

                                function parseLogItem(log) {
                                  const parseMessage = [
                                    '(.*)\\s-\\s\\[(.*)]\\s"([^"]*)(HTTP/.*)"\\s(\\d+)\\s.*',
                                    'x_forwarded_for:"(.*)"\\sx_forwarded_proto:"(\\w+)"\\',
                                    "svcap_request_id:(.*)\\sresponse_time:(.*)\\sapp_id:(.*)"
                                Severity: Minor
                                Found in static_src/stores/activity_store.js - About 1 hr to fix

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

                                    render() {
                                      let content = <div />;
                                      const serviceInstance = this.props.serviceInstance;
                                  
                                      if (serviceInstance) {
                                  Severity: Minor
                                  Found in static_src/components/service_instance.jsx - About 1 hr to fix

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

                                      render() {
                                        const emptyMessage = this.props.emptyMessage && (
                                          <div className="complex_list-empty">{this.props.emptyMessage}</div>
                                        );
                                        let header;
                                    Severity: Minor
                                    Found in static_src/components/complex_list.jsx - About 1 hr to fix

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

                                        get emptyState() {
                                          let content;
                                          let callout;
                                      
                                          if (this.state.currentUserCanViewSpace) {
                                      Severity: Minor
                                      Found in static_src/components/org_container.jsx - About 1 hr to fix

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

                                          render() {
                                            const state = this.state;
                                            const loading = <Loading text="Loading orgs" />;
                                            let content = <div>{loading}</div>;
                                            const title = (
                                        Severity: Minor
                                        Found in static_src/components/overview_container.jsx - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language