| 1010 | if ( -1 !== _.indexOf( plugins['auto-update-enabled'], response.plugin ) ) { |
| 1011 | plugins['auto-update-enabled'] = _.without( plugins['auto-update-enabled'], response.plugin ); |
| 1012 | if ( plugins['auto-update-enabled'].length ) { |
| 1013 | $views.find( '.auto-update-enabled .count' ).text( '(' + plugins['auto-update-enabled'].length + ')' ); |
| 1014 | } else { |
| 1015 | $views.find( '.auto-update-enabled' ).remove(); |
| 1016 | } |
| 1017 | } |
| 1018 | |
| 1019 | if ( -1 !== _.indexOf( plugins['auto-update-disabled'], response.plugin ) ) { |
| 1020 | plugins['auto-update-disabled'] = _.without( plugins['auto-update-disabled'], response.plugin ); |
| 1021 | if ( plugins['auto-update-disabled'].length ) { |
| 1022 | $views.find( '.auto-update-disabled .count' ).text( '(' + plugins['auto-update-disabled'].length + ')' ); |
| 1023 | } else { |
| 1024 | $views.find( '.auto-update-disabled' ).remove(); |
| 1025 | } |
| 1026 | } |
| 1027 | |