#57183 closed defect (bug) (fixed)
After deleting updateable themes, the incorrect update count is displayed.
Reported by: | nazmulhasan103 | Owned by: | audrasjb |
---|---|---|---|
Milestone: | 6.2 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Upgrade/Install | Keywords: | has-patch has-testing-info has-screenshots commit |
Focuses: | javascript, administration | Cc: |
Description
Even though I deleted an updateable theme since it didn't immediately update the decremented total, everything is OK after refreshing the page.
- When an updateable theme is deleted: https://prnt.sc/3ugZBS9cRboF
- After refreshing the page: https://prnt.sc/tcvo1x6qBwno
Change History (23)
This ticket was mentioned in PR #3669 on WordPress/wordpress-develop by themeaazz.
23 months ago
#1
- Keywords has-patch added
#2
@
23 months ago
Hi @nazmulhasan103,
how about moving your if before:
wp.a11y.speak( _x( 'Deleted!', 'theme' ) );
I was looking at the code again, do you decrease the number of updates even if you delete a theme that doesn't need to be updated? I'm wrong?
If you look a little above you can take a hint from here:
// Remove theme from update count. if ( -1 !== _.indexOf( themes.upgrade, response.slug ) ) { themes.upgrade = _.without( themes.upgrade, response.slug ); wp.updates.decrementCount( 'theme' ); }
#4
@
23 months ago
- Component changed from Administration to Upgrade/Install
- Keywords needs-testing added
- Type changed from feature request to defect (bug)
- Version 6.1.1 deleted
@Hinjiriyo shared steps to reproduce the bug (or to test a patch) in #52306.
How to reproduce the bug:
- The Update icon in the admin bar shows a number of available updates. There is at least one inactive, outdated theme (e.g. a theme for which an upgrade is available, and it is not the active theme).
- Go to "Appearance" > "Themes" and delete that theme.
- Since there is one outdated item less, you would expect a number reduced by 1 at the Update icon. But the number remains unchanged.
I'll add Step 4: Check the number next to "Themes" in the admin side menu to verify that it also is reduced by one.
This ticket was mentioned in PR #3671 on WordPress/wordpress-develop by @riccardodicurti.
23 months ago
#5
After deleting updatable themes, the incorrect update count is displayed.
Trac ticket: https://core.trac.wordpress.org/ticket/57183
This ticket was mentioned in Slack in #core-test by ironprogrammer. View the logs.
23 months ago
#7
@
23 months ago
- Keywords has-testing-info has-screenshots added
Welcome to Trac, and thank you for this report, @nazmulhasan103!
To move this forward, it would be great to have an issue reproduction report, followed by a patch test report.
#8
@
23 months ago
Reproduction Report
This report validates that the issue can be reproduced.
Environment
- Server: Apache (Linux)
- WordPress: 6.2-alpha-54642-src
- Browser: Chrome 107.0.0.0
- OS: Windows 10
- Theme: Twenty Twenty-Two
- Plugins: None activated
Actual Results
- ✅ Error condition occurs (reproduced).
#9
follow-up:
↓ 12
@
23 months ago
Test Report
This report validates that the indicated patch addresses the issue.
Patch tested: https://github.com/WordPress/wordpress-develop/pull/3669
Environment
- Server: Apache (Linux)
- WordPress: 6.2-alpha-54642-src
- Browser: Chrome 107.0.0.0
- OS: Windows 10
- Theme: Twenty Twenty-Two
- Plugins: None activated
Actual Results
- ✅ Issue resolved with patch.
#10
@
23 months ago
Test Report
This report validates that the indicated patch addresses the issue.
Patch tested: https://github.com/WordPress/wordpress-develop/pull/3671
Environment
- Server: Apache (Linux)
- WordPress: 6.2-alpha-54642-src
- Browser: Chrome 107.0.0.0
- OS: Windows 10
- Theme: Twenty Twenty-Two
- Plugins: None activated
Actual Results
- ✅ Issue resolved with patch.
#11
@
23 months ago
- Milestone changed from Awaiting Review to 6.2
Both patches resolve the issue.
Milestoning for 6.2
so that both PRs can be reviewed to determine the desired one to move forward with.
This ticket was mentioned in Slack in #core-upgrade-install by afragen. View the logs.
23 months ago
This ticket was mentioned in Slack in #core-upgrade-install by costdev. View the logs.
22 months ago
#15
@
21 months ago
First of all https://github.com/WordPress/wordpress-develop/pull/3669 looks better to me as it contains proper spacing, semi colon, doc block etc.
And passed all checks.
I will submit test report soon here.
https://github.com/WordPress/wordpress-develop/pull/3669
#16
@
21 months ago
Test Report
This report validates that the indicated patch addresses the issue.
Patch tested: https://patch-diff.githubusercontent.com/raw/WordPress/wordpress-develop/pull/3669.diff
Environment
- OS: macOS 11.2.3
- Web Server: Nginx
- PHP: 7.4.30
- WordPress: 6.2-alpha-54642-src
- Browser: Chrome 109.0.5414.119
- Theme: Twenty Twenty-One
- Active Plugins:
- No plugins activated
Actual Results
- ✅ Issue resolved with patch.
Additional Notes
- Successfully reproduced the issue
- Applied patch fix the count of the top icon as well as left sidebar icon
Supplemental Artifacts
Before: https://d.pr/i/zr7V5T
After: https://d.pr/i/BNb1Z8
#17
@
21 months ago
Test Report
This report validates that the indicated patch addresses the issue.
Patch tested: https://patch-diff.githubusercontent.com/raw/WordPress/wordpress-develop/pull/3669.diff
Environment
- OS: macOS 13.1
- Web Server: Nginx
- PHP: 7.4.33
- WordPress: 6.2-alpha-54642-src
- Browser: Chrome
- Theme: Twenty Twenty-Three
- Active Plugins:
- No plugins activated
Actual Results
- ✅ Issue resolved with patch.
When 2 themes were downgraded, this issue appeared: https://prnt.sc/w75T1ENIpJlE
After the patch was applied, the issue was resolved: https://prnt.sc/Mmky91kdSsCK
This ticket was mentioned in Slack in #core by costdev. View the logs.
20 months ago
#20
@
20 months ago
- Keywords commit added
This ticket was reviewed during the recent bug scrub. Adding for commit
consideration.
Additional props: @hellofromTonya
#21
@
20 months ago
- Owner set to audrasjb
- Status changed from new to accepted
Self assigning for commit
consideration.
Trac ticket: https://core.trac.wordpress.org/ticket/57183