Opened 14 hours ago
Closed 10 hours ago
#65730 closed defect (bug) (invalid)
Fix template `modified` return value for file templates
| Reported by: | ntsekouras | Owned by: | ntsekouras |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | General | Version: | |
| Severity: | normal | Keywords: | has-patch has-unit-tests |
| Cc: | Focuses: |
Description (last modified by )
Recently we added the date field for template and template parts (https://core.trac.wordpress.org/ticket/65049) and it was noted that the returned value from REST API could return false for file templates. This will be fixed here: https://core.trac.wordpress.org/ticket/65728 for 7.1.
While looking into the above issue, I observed that we have the same issue for modified property since 6.3.
We should update the type to be the same with date to string|null and not return false for file templates.
Change History (4)
This ticket was mentioned in PR #12711 on WordPress/wordpress-develop by @ntsekouras.
13 hours ago
#2
- Keywords has-patch has-unit-tests added
@ntsekouras commented on PR #12711:
10 hours ago
#3
Changes will be included here: https://github.com/WordPress/wordpress-develop/pull/12709
#4
@
10 hours ago
- Milestone 7.2
- Resolution → invalid
- Status assigned → closed
Changes will be included here: https://github.com/WordPress/wordpress-develop/pull/12709
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Trac ticket: https://core.trac.wordpress.org/ticket/65730
Backports: https://github.com/WordPress/gutenberg/pull/80733
## What?
Recently we added the
datefield for template and template parts (https://core.trac.wordpress.org/ticket/65049) and it was noted that the returned value from REST API could returnfalsefor file templates. This will be fixed here: https://core.trac.wordpress.org/ticket/65728 for7.1.While looking into the above issue, I observed that we have the same issue for
modifiedproperty since6.3.We should update the type to be the same with
datetostring|nulland not returnfalsefor file templates.This PR updates the
modifiedprop to also returnnullfor file templates.## Testing instructions
. Then inspecttemplates`modifiedisnullfor file templates.## Use of AI Tools
Opus 5 with direction, changes and review