glitch-soc/mastodon

View on GitHub

Showing 4,938 of 4,938 total issues

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

  _updateLinks () {
    const node = this.node;

    if (!node) {
      return;

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

      render () {
        const { intl, hasMore, accountIds, multiColumn, isLoading } = this.props;
    
        if (!accountIds) {
          return (
    Severity: Minor
    Found in app/javascript/flavours/glitch/features/mutes/index.jsx - About 1 hr to fix

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

        render () {
          const { emoji, emojiMap, hovered } = this.props;
      
          if (unicodeMapping[emoji]) {
            const { filename, shortCode } = unicodeMapping[this.props.emoji];

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

          render () {
            const { intl, lists, multiColumn } = this.props;
        
            if (!lists) {
              return (
        Severity: Minor
        Found in app/javascript/flavours/glitch/features/lists/index.jsx - About 1 hr to fix

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

            render () {
              const { status, checked } = this.props;
          
              if (status.get('reblog')) {
                return null;

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

              render () {
                const { intl, hidden, report, account } = this.props;
            
                if (!report) {
                  return null;

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

              export function submitSearch(type) {
                return (dispatch, getState) => {
                  const value    = getState().getIn(['search', 'value']);
                  const signedIn = !!getState().getIn(['meta', 'me']);
              
              
              Severity: Minor
              Found in app/javascript/mastodon/actions/search.js - About 1 hr to fix

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

                export default function server(state = initialState, action) {
                  switch (action.type) {
                  case SERVER_FETCH_REQUEST:
                    return state.setIn(['server', 'isLoading'], true);
                  case SERVER_FETCH_SUCCESS:
                Severity: Minor
                Found in app/javascript/flavours/glitch/reducers/server.js - About 1 hr to fix

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

                    render () {
                      const { poll, intl } = this.props;
                      const { revealed, expired } = this.state;
                  
                      if (!poll) {
                  Severity: Minor
                  Found in app/javascript/mastodon/components/poll.jsx - About 1 hr to fix

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

                      render () {
                        const { emoji, emojiMap, hovered } = this.props;
                    
                        if (unicodeMapping[emoji]) {
                          const { filename, shortCode } = unicodeMapping[this.props.emoji];

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

                        _updateLinks () {
                          const node = this.node;
                      
                          if (!node) {
                            return;

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

                          render () {
                            const { media, status, onClose } = this.props;
                            const options = this.props.options || {};
                            const language = status.getIn(['translation', 'language']) || status.get('language');
                            const description = media.getIn(['translation', 'description']) || media.get('description');
                        Severity: Minor
                        Found in app/javascript/mastodon/features/ui/components/video_modal.jsx - About 1 hr to fix

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

                            render () {
                              const { intl, hasMore, accountIds, multiColumn, isLoading } = this.props;
                          
                              if (!accountIds) {
                                return (
                          Severity: Minor
                          Found in app/javascript/mastodon/features/mutes/index.jsx - About 1 hr to fix

                            Method calculate_scores has 28 lines of code (exceeds 25 allowed). Consider refactoring.
                            Open

                              def calculate_scores(preview_cards, at_time)
                                items = preview_cards.map do |preview_card|
                                  expected  = preview_card.history.get(at_time - 1.day).accounts.to_f
                                  expected  = 1.0 if expected.zero?
                                  observed  = preview_card.history.get(at_time).accounts.to_f
                            Severity: Minor
                            Found in app/models/trends/links.rb - About 1 hr to fix

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

                              export default function server(state = initialState, action) {
                                switch (action.type) {
                                case SERVER_FETCH_REQUEST:
                                  return state.setIn(['server', 'isLoading'], true);
                                case SERVER_FETCH_SUCCESS:
                              Severity: Minor
                              Found in app/javascript/mastodon/reducers/server.js - About 1 hr to fix

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

                                  render () {
                                    const { intl, hidden, report, account } = this.props;
                                
                                    if (!report) {
                                      return null;

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

                                    renderStatus (notification, link) {
                                      const { intl, unread, status } = this.props;
                                  
                                      if (!status) {
                                        return null;

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

                                      renderUpdate (notification, link) {
                                        const { intl, unread, status } = this.props;
                                    
                                        if (!status) {
                                          return null;

                                      Method import_bookmarks! has 28 lines of code (exceeds 25 allowed). Consider refactoring.
                                      Open

                                        def import_bookmarks!
                                          parse_import_data!(['#uri'])
                                          items = @data.take(ROWS_PROCESSING_LIMIT).map { |row| row['#uri'].strip }
                                      
                                          if @import.overwrite?
                                      Severity: Minor
                                      Found in app/services/import_service.rb - About 1 hr to fix

                                        Method account_link_to has 28 lines of code (exceeds 25 allowed). Consider refactoring.
                                        Open

                                          def account_link_to(account, button = '', path: nil)
                                            content_tag(:div, class: 'account account--minimal') do
                                              content_tag(:div, class: 'account__wrapper') do
                                                section = if account.nil?
                                                            content_tag(:div, class: 'account__display-name') do
                                        Severity: Minor
                                        Found in app/helpers/home_helper.rb - About 1 hr to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language