	wp.updates.decrementCount = function( type ) {
		var $adminBarUpdates             = $( '#wp-admin-bar-updates' ),
			$dashboardNavMenuUpdateCount = $( 'a[href="update-core.php"] .update-plugins' ),
			count                        = $adminBarUpdates.find( '.ab-label' ).text(),
			$menuItem, $itemCount, itemCount;

		count = parseInt( count, 10 ) - 1;

		if ( count < 0 || isNaN( count ) ) {
			return;
		}

		$adminBarUpdates.find( '.ab-item' ).removeAttr( 'title' );
		$adminBarUpdates.find( '.ab-label' ).text( count );

		// Remove the update count from the toolbar if it's zero.
		if ( ! count ) {
			$adminBarUpdates.find( '.ab-label' ).parents( 'li' ).remove();
		}

		// Update the "Updates" menu item.
		$dashboardNavMenuUpdateCount.each( function( index, element ) {
			element.className = element.className.replace( /count-\d+/, 'count-' + count );
		} );

		$dashboardNavMenuUpdateCount.removeAttr( 'title' );
		$dashboardNavMenuUpdateCount.find( '.update-count' ).text( count );

		switch ( type ) {
			case 'plugin':
				$menuItem  = $( '#menu-plugins' );
				$itemCount = $menuItem.find( '.plugin-count' );
				break;

			case 'theme':
				$menuItem  = $( '#menu-appearance' );
				$itemCount = $menuItem.find( '.theme-count' );
				break;

			default:
				window.console.error( '"%s" is not white-listed to have its count decremented.', type );
				return;
		}

		// Decrement the counter of the other menu items.
		if ( $itemCount ) {
			itemCount = $itemCount.eq( 0 ).text();
			itemCount = parseInt( itemCount, 10 ) - 1;
		}

		if ( itemCount < 0 || isNaN( itemCount ) ) {
			return;
		}

		if ( itemCount > 0 ) {
			$( '.subsubsub .upgrade .count' ).text( '(' + itemCount + ')' );

			$itemCount.text( itemCount );
			$menuItem.find( '.update-plugins' ).each( function( index, element ) {
				element.className = element.className.replace( /count-\d+/, 'count-' + itemCount );
			} );
		} else {
			$( '.subsubsub .upgrade' ).remove();
			$menuItem.find( '.update-plugins' ).remove();
		}
	};
The web application does not, or can not, sufficiently verify whether a well-formed, valid, consistent request was intentionally provided by the user who submitted the request.