Commit Graph

14825 Commits

Author SHA1 Message Date
Sergey Biryukov
44288356e2 Menus: Introduce wp_nav_menu_item_custom_fields action that fires just before the move buttons of a nav menu item in the menu editor.
Props MikeSchinkel, birgire, sebastian.pisula, desrosj, helgatheviking.
Fixes #47056. See #38904, #18584.
Built from https://develop.svn.wordpress.org/trunk@47190


git-svn-id: http://core.svn.wordpress.org/trunk@46990 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 07:43:05 +00:00
Sergey Biryukov
84c43d1863 Docs: Correct type for $item and $args parameters in Walker_Nav_Menu_Checklist and Walker_Nav_Menu_Edit to match the parent Walker_Nav_Menu` class.
Follow-up to [38559], [45537].

See #24587, #48303.
Built from https://develop.svn.wordpress.org/trunk@47189


git-svn-id: http://core.svn.wordpress.org/trunk@46989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 07:25:05 +00:00
Sergey Biryukov
c32e05f308 Site Health: Improve focus style for accordion items on Site Health screens.
The new style is more consistent with other elements like `.wp-core-ui` buttons.

Props audrasjb, mensmaximus, afercia, melchoyce, Clorith.
Fixes #48578.
Built from https://develop.svn.wordpress.org/trunk@47188


git-svn-id: http://core.svn.wordpress.org/trunk@46988 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 06:43:04 +00:00
Sergey Biryukov
fa0563c877 Docs: Add a @since note for [47186].
See #48558.
Built from https://develop.svn.wordpress.org/trunk@47187


git-svn-id: http://core.svn.wordpress.org/trunk@46987 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 06:33:04 +00:00
Sergey Biryukov
4f422b028d Taxonomy: In register_taxonomy(), return the registered taxonomy object on success, for consistency with register_post_type().
Props krynes, SergeyBiryukov.
Fixes #48558.
Built from https://develop.svn.wordpress.org/trunk@47186


git-svn-id: http://core.svn.wordpress.org/trunk@46986 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 06:26:06 +00:00
Sergey Biryukov
b3f75c66f4 Coding Standards: Fix WPCS issue in [47184].
See #49344.
Built from https://develop.svn.wordpress.org/trunk@47185


git-svn-id: http://core.svn.wordpress.org/trunk@46985 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 05:03:05 +00:00
Sergey Biryukov
0561e81ecc Tests: Allow dbDelta() tests to (mostly) run on MySQL 8.0.11+.
* MySQL 8.0.11 changed the `GeometryCollection` data type name to `GeomCollection`, with the latter being the preferred name.
* MySQL 8.0.17 removed support for the display width attribute for integer data types. Previously, default display width of 20 digits was used: `BIGINT(20)`.

The affected tests now check the MySQL server version and use the appropriate data types.

This leaves one unresolved failure on MySQL 8.0.17+ to be addressed in the future, caused by the same `BIGINT` display width discrepancy coming from `wp_get_db_schema()`.

Props kaggdesign, ottok, jeremyfelt, SergeyBiryukov.
Fixes #44384, #49344. See #49364.
Built from https://develop.svn.wordpress.org/trunk@47184


git-svn-id: http://core.svn.wordpress.org/trunk@46984 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 04:30:04 +00:00
Sergey Biryukov
ccdc1db0a9 Tests: Allow wpdb::set_sql_mode() tests to run on MySQL 8.0.11+.
MySQL 8.0.11 removed support for the `NO_AUTO_CREATE_USER` SQL mode, which was used in as an example of a mode compatible with WordPress.

`NO_AUTO_VALUE_ON_ZERO` is now used in the affected tests instead, which is supported on both MySQL 5.7.x and 8.0.x.

Props kaggdesign, jeremyfelt, afragen.
Fixes #44586. See #49344.
Built from https://develop.svn.wordpress.org/trunk@47183


git-svn-id: http://core.svn.wordpress.org/trunk@46983 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 03:30:05 +00:00
Sergey Biryukov
e2440d55e7 Docs: Clarify that is_page_template() accepts a template filename, not the Template Name file header.
Props mkaz.
Fixes #49362.
Built from https://develop.svn.wordpress.org/trunk@47182


git-svn-id: http://core.svn.wordpress.org/trunk@46982 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 03:14:06 +00:00
Sergey Biryukov
a16f3f8f13 Posts, Post Types: Fail gracefully when checking whether a single post with an unregistered post status should be displayed in WP_Query::get_posts().
If the post status is not registered, assume it's not public, but still allow access to users with edit permissions (same as for a protected post status, e.g. `draft`), so that they could recover orphaned content.

Add unit tests.

Follow-up to [47178].

Props roytanck, SergeyBiryukov.
Fixes #48653.
Built from https://develop.svn.wordpress.org/trunk@47181


git-svn-id: http://core.svn.wordpress.org/trunk@46981 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-05 01:33:05 +00:00
Sergey Biryukov
da6f24fba9 Posts, Post Types: Revert [47179] pending test failures investigation.
See #48653.
Built from https://develop.svn.wordpress.org/trunk@47180


git-svn-id: http://core.svn.wordpress.org/trunk@46980 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 23:02:09 +00:00
Sergey Biryukov
73a088f5b6 Posts, Post Types: Fail gracefully when checking whether the post should be displayed in WP_Query::get_posts() against unregistered post status.
If the post status is not registered, assume it's not public.

Follow-up to [47178].

Props roytanck.
See #48653.
Built from https://develop.svn.wordpress.org/trunk@47179


git-svn-id: http://core.svn.wordpress.org/trunk@46979 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 22:22:06 +00:00
Sergey Biryukov
46951e0b17 Posts, Post Types: Fail gracefully when checking mapped cap against unregistered post status.
With `map_meta_cap` enabled for a post type, the `read_post` capability for posts with a public status is supposed to be mapped to the post type's `read` capability.

When a post is left in the database after the post status is no longer present, and WP does a `read_post` check against it, a PHP notice was thrown, and the cap check always failed.

As a more graceful fallback, the cap is now mapped onto `edit_others_posts`, which allows highly privileged users to be able to access orphaned content.

A `_doing_it_wrong()` notice is also added, so that developers and site administrators are aware that the cap mapping is failing in the absence of the registered post status.

Follow-up to [34091], which introduced a similar approach to checking mapped caps against an unregistered post type.

Props roytanck, SergeyBiryukov.
Fixes #48653.
Built from https://develop.svn.wordpress.org/trunk@47178


git-svn-id: http://core.svn.wordpress.org/trunk@46978 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 22:15:08 +00:00
Sergey Biryukov
3882b3f567 Coding Standards: Fix WPCS issues in [47175].
See #49361.
Built from https://develop.svn.wordpress.org/trunk@47177


git-svn-id: http://core.svn.wordpress.org/trunk@46977 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 21:42:04 +00:00
jorgefilipecosta
d7e321c7c7 Block Editor: Include navigation block server logic.
Core did not include the navigation block PHP files.
This commit fixes the issue referred, and now the navigation block is executed on the frontend. The block still does not work as expected and throws an error during frontend execution. That problem is going to be fixed on the next WordPress package update.
This commit adds the file as it is on the npm package used.

Props gziolo.
Fixes #49348.
Built from https://develop.svn.wordpress.org/trunk@47176


git-svn-id: http://core.svn.wordpress.org/trunk@46976 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 20:16:04 +00:00
Sergey Biryukov
d3a9952838 Users: Pass the $reassign parameter to the remove_user_from_blog action.
Props Tivus.
Fixes #49361.
Built from https://develop.svn.wordpress.org/trunk@47175


git-svn-id: http://core.svn.wordpress.org/trunk@46975 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 19:43:03 +00:00
Sergey Biryukov
761644c636 Docs: Improve description for add_user_to_blog() and remove_user_from_blog() parameters.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47174


git-svn-id: http://core.svn.wordpress.org/trunk@46974 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 19:40:06 +00:00
Sergey Biryukov
be057c4a1c Users: In remove_user_from_blog():
* Change default value of the `$blog_id` parameter to match the documented type.
* Change the type of the `$reassign` parameter for consistency with `$user_id` and `$blog_id`.
* Add documentation for the return value.

See #49361.
Built from https://develop.svn.wordpress.org/trunk@47173


git-svn-id: http://core.svn.wordpress.org/trunk@46973 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 19:36:04 +00:00
Sergey Biryukov
e956bbebe1 TinyMCE: Remove duplicate keys and strings from langs/wp-langs-en.js.
Props david.binda.
Fixes #49359.
Built from https://develop.svn.wordpress.org/trunk@47172


git-svn-id: http://core.svn.wordpress.org/trunk@46972 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 16:43:07 +00:00
Sergey Biryukov
143c6a1de8 Database: Add ANSI to the list of incompatible SQL modes.
Starting with MySQL 5.7.5, the `ANSI` mode implies `ONLY_FULL_GROUP_BY`, which is already listed in `wpdb` as incompatible per [27072].

When `ANSI` is enabled on MySQL 5.7.5+, `ONLY_FULL_GROUP_BY` remains enabled even after being "unset" by `wpdb::set_sql_mode()`.

To prevent this, the `ANSI` mode should also be listed as incompatible. It is not enabled on default MySQL installations.

Props jnylen0.
Fixes #48377.
Built from https://develop.svn.wordpress.org/trunk@47171


git-svn-id: http://core.svn.wordpress.org/trunk@46971 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-04 01:14:07 +00:00
Sergey Biryukov
c289bb59ac Docs: Improve documentation for WP_Dependencies, WP_Scripts, and WP_Styles methods.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47170


git-svn-id: http://core.svn.wordpress.org/trunk@46970 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-03 00:19:03 +00:00
Sergey Biryukov
982a6453c9 Canonical: When removing trailing punctuation from query string arguments, match the whole query var name.
Props daveslaughter.
Fixes #49347.
Built from https://develop.svn.wordpress.org/trunk@47169


git-svn-id: http://core.svn.wordpress.org/trunk@46969 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-03 00:14:07 +00:00
gziolo
bfc5248126 Build: Copy block metadata files for dynamic blocks.
For dynamic blocks, there are several blocks whose metadata needs to be loaded in PHP. The attributes that are loaded via PHP are not exposed to the ReactNative components when Gutenberg loads the index.js files in the Mobile Apps. To support one master set of metadata that can be used to register in the PHP files and the Javascript files; with this patch, the block.json files are copied over with their corresponding PHP files.

Props chipsnyder and azaozz.

Fixes #49196.


Built from https://develop.svn.wordpress.org/trunk@47168


git-svn-id: http://core.svn.wordpress.org/trunk@46968 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 19:19:04 +00:00
Sergey Biryukov
8163215dc4 Plugins: Remove obsolete plugin_slugs transient from WP_Plugins_List_Table::prepare_items().
The transient is only used in the `wp_dashboard_plugins_output()` function, which is deprecated and unused since [40607].

The function itself also sets the same transient, so it can be removed from `WP_Plugins_List_Table`.

Props aftabmuni.
Fixes #49340.
Built from https://develop.svn.wordpress.org/trunk@47167


git-svn-id: http://core.svn.wordpress.org/trunk@46967 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 15:50:04 +00:00
Sergey Biryukov
e79f7f71aa REST API: Merge "not allowed to create new terms" permission error message with an existing string.
Follow-up to [39309], [39313].

See #38857.
Built from https://develop.svn.wordpress.org/trunk@47166


git-svn-id: http://core.svn.wordpress.org/trunk@46966 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 05:41:03 +00:00
Sergey Biryukov
f51b4579d5 Docs: Fix typo in a comment with WP_DEBUG_DISPLAY description.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47165


git-svn-id: http://core.svn.wordpress.org/trunk@46965 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 05:34:05 +00:00
Sergey Biryukov
11fb46d4c6 Editor: Remove back-compat stub for Classic Editor's old distraction-free writing mode.
The original script was deprecated in [30338] and removed in [32677].

Props Presskopp, ketuchetan.
Fixes #39448.
Built from https://develop.svn.wordpress.org/trunk@47164


git-svn-id: http://core.svn.wordpress.org/trunk@46964 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 04:15:03 +00:00
Sergey Biryukov
9ce9450bf9 Tests: Adjust XML-RPC unit tests for [47160].
Follow-up to [47162].

See #40096.
Built from https://develop.svn.wordpress.org/trunk@47163


git-svn-id: http://core.svn.wordpress.org/trunk@46963 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 04:09:04 +00:00
Sergey Biryukov
11dc73b383 Tests: Adjust XML-RPC unit tests for [47160].
See #40096.
Built from https://develop.svn.wordpress.org/trunk@47162


git-svn-id: http://core.svn.wordpress.org/trunk@46962 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 03:32:04 +00:00
Sergey Biryukov
2f58dc5ce9 Docs: Add more specific description for WP_Http::processResponse() return value.
Props marekdedic, takeshifurusato.
Fixes #48351.
Built from https://develop.svn.wordpress.org/trunk@47161


git-svn-id: http://core.svn.wordpress.org/trunk@46961 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 03:27:05 +00:00
Sergey Biryukov
7e331ab235 Post Thumbnails: Make sure get_post_thumbnail_id() returns an integer, to match the documented return value.
This makes the function more consistent with `get_the_ID()` or `wp_get_post_parent_id()`, both returning an integer.

Props 0v3rth3d4wn.
Fixes #40096.
Built from https://develop.svn.wordpress.org/trunk@47160


git-svn-id: http://core.svn.wordpress.org/trunk@46960 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 03:08:04 +00:00
Sergey Biryukov
c94722d9bc Docs: Improve inline comments in wp-admin/options.php per the documentation standards.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47159


git-svn-id: http://core.svn.wordpress.org/trunk@46959 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-02 02:42:04 +00:00
Sergey Biryukov
a0f8b7003b Administration: Include options page name in the "Options page not found" error message to provide better context for plugin developers.
Props tdlewis77, williampatton.
Fixes #42941.
Built from https://develop.svn.wordpress.org/trunk@47158


git-svn-id: http://core.svn.wordpress.org/trunk@46958 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 22:42:06 +00:00
Sergey Biryukov
8e37999368 Docs: Correct DocBlock formatting for register_setting().
Document the full list of whitelisted option key names.

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47157


git-svn-id: http://core.svn.wordpress.org/trunk@46957 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 22:01:07 +00:00
Sergey Biryukov
deb1886078 Accessibility: Text Changes: Use sentence case for the word Error in various error messages, instead of all caps.
Using all caps should be avoided for better readability and because screen readers may pronounce all-caps words as abbreviations.

Props afercia, ryokuhi, sabernhardt, garrett-eclipse.
See #47656, #43037, #42945.
Built from https://develop.svn.wordpress.org/trunk@47156


git-svn-id: http://core.svn.wordpress.org/trunk@46956 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 21:38:04 +00:00
Sergey Biryukov
15a6accec4 Tests: Update the expected message in test_with_draft_post().
Follow-up to [47154].

See #42945.
Built from https://develop.svn.wordpress.org/trunk@47155


git-svn-id: http://core.svn.wordpress.org/trunk@46955 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 21:13:05 +00:00
Sergey Biryukov
2fe7c95153 Text Changes: Capitalize error messages consistently.
Props Presskopp.
Fixes #42945.
Built from https://develop.svn.wordpress.org/trunk@47154


git-svn-id: http://core.svn.wordpress.org/trunk@46954 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 20:55:05 +00:00
Sergey Biryukov
12a6907123 Text Changes: Add missing periods to some error messages, for consistency.
Props Presskopp.
Fixes #42735.
Built from https://develop.svn.wordpress.org/trunk@47153


git-svn-id: http://core.svn.wordpress.org/trunk@46953 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 20:32:05 +00:00
Sergey Biryukov
21548ad0de Text Changes: Add missing periods to comment status update notices, for consistency.
Props Presskopp.
See #42735.
Built from https://develop.svn.wordpress.org/trunk@47152


git-svn-id: http://core.svn.wordpress.org/trunk@46952 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 20:29:05 +00:00
Sergey Biryukov
f65bc1401a Networks and Sites: Reduce max-width for user and site search inputs on Dashboard screen in Network Admin.
This ensures that the inputs don't push the buttons to the next line.

Props williampatton, bordoni.
Fixes #49043.
Built from https://develop.svn.wordpress.org/trunk@47151


git-svn-id: http://core.svn.wordpress.org/trunk@46951 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 17:38:03 +00:00
Sergey Biryukov
06979c6597 Docs: Document the addition of $json_report_pathname parameter to the wp_privacy_personal_data_export_file_created action.
Follow-up to [47146].

Props xkon.
Fixes #49029.
Built from https://develop.svn.wordpress.org/trunk@47150


git-svn-id: http://core.svn.wordpress.org/trunk@46950 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 04:17:05 +00:00
Sergey Biryukov
0aff1cf6bd Site Health: Rename WP_Site_Health::initialize() introduced in [47063] to ::get_instance(), for clarity and consistency with other core classes.
Use `WP_Site_Health::get_instance()` where it's needed, instead of creating multiple instances of the class.

Props afercia, xkon, Clorith, SergeyBiryukov.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47149


git-svn-id: http://core.svn.wordpress.org/trunk@46949 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 00:39:09 +00:00
Sergey Biryukov
3cd1514b91 Privacy: Clarify bulk action labels for personal data export and removal requests.
Props garrett-eclipse, xkon, shariqkhan2012, websupporter, desrosj, JoshuaWold.
Fixes #44674.
Built from https://develop.svn.wordpress.org/trunk@47148


git-svn-id: http://core.svn.wordpress.org/trunk@46948 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 03:43:05 +00:00
Sergey Biryukov
aef48b433b Accessibility: Privacy: Improve the readability of the suggested text in Privacy Policy Guide.
Per WCAG 2.0 guidelines, big chunks of italic text should be avoided for better accessibility.

Props birgire, sabernhardt, xkon, garrett-eclipse, melchoyce, karmatosed, afercia, jepperask, SergeyBiryukov.
Fixes #44621. See #47327.
Built from https://develop.svn.wordpress.org/trunk@47147


git-svn-id: http://core.svn.wordpress.org/trunk@46947 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 03:25:05 +00:00
Sergey Biryukov
39cef6947a Privacy: Introduce a JSON file into the personal data export.
The produced ZIP archive will now include an `export.json` file along with the current `index.html`.

Props xkon.
Fixes #49029. See #46424.
Built from https://develop.svn.wordpress.org/trunk@47146


git-svn-id: http://core.svn.wordpress.org/trunk@46946 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 01:36:05 +00:00
Sergey Biryukov
d0a0825809 Site Health: Add support for required WordPress and PHP versions to themes.
Follow-up to [45546] for plugins.

Props flixos90, afragen.
Fixes #44592. See #40934, #meta3718.
Built from https://develop.svn.wordpress.org/trunk@47145


git-svn-id: http://core.svn.wordpress.org/trunk@46945 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 01:17:04 +00:00
Sergey Biryukov
eafc40be6d Privacy: Remove user's email address from personal data export filename.
Use `wp_unique_filename()` to avoid potential collisions instead.

Props xkon, garrett-eclipse, donmhico, Ov3rfly, Clorith, allendav.
Fixes #44197.
Built from https://develop.svn.wordpress.org/trunk@47144


git-svn-id: http://core.svn.wordpress.org/trunk@46944 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 00:58:06 +00:00
Sergey Biryukov
4f67024da6 Administration: Add punctuation to "If you change this, we will send you an email" message on General Settings, Network Settings, and Profile screens.
Props kinjaldalwadi, donmhico.
Fixes #49235.
Built from https://develop.svn.wordpress.org/trunk@47143


git-svn-id: http://core.svn.wordpress.org/trunk@46943 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 00:28:04 +00:00
Sergey Biryukov
6c05771d55 HTTP API: Add some basic tests for wp_remote_fopen().
Props pbearne, donmhico.
Fixes #48845.
Built from https://develop.svn.wordpress.org/trunk@47142


git-svn-id: http://core.svn.wordpress.org/trunk@46942 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 00:22:05 +00:00
Sergey Biryukov
60f5fa9367 Tests: Rename wpValidateBoolean.php for consistency with other files.
See #30238.
Built from https://develop.svn.wordpress.org/trunk@47141


git-svn-id: http://core.svn.wordpress.org/trunk@46941 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 00:16:04 +00:00
Sergey Biryukov
3b9cddaea5 Twenty Nineteen: Remove duplicate font-size property.
The theme does not use a `px` fallback for `rem` units anywhere else.

Follow-up to [47053] for Twenty Twenty.

See #49015.
Built from https://develop.svn.wordpress.org/trunk@47140


git-svn-id: http://core.svn.wordpress.org/trunk@46940 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-31 00:09:08 +00:00
ianbelanger
9fc09b2720 Fixes PHPCS Introduced in [47135].
There was extra whitespace in the previous commit, this removes it.

See #48552
Built from https://develop.svn.wordpress.org/trunk@47139


git-svn-id: http://core.svn.wordpress.org/trunk@46939 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-30 21:55:05 +00:00
K. Adam White
b78819c3fa REST API: Reuse previously-generated embedded objects when building collection response.
Store each generated embedded object in a temporary cache when querying for linked resources so that repeated links to the same resource do not trigger repeated queries or processing.

Props TimothyBlynJacobs.
Fixes #48838.


Built from https://develop.svn.wordpress.org/trunk@47138


git-svn-id: http://core.svn.wordpress.org/trunk@46938 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-30 20:22:07 +00:00
Sergey Biryukov
d80131190f Twenty Nineteen: Standardize the Required PHP and Tested Up To headers.
* Remove `WordPress` from `Requires at least` headers.
* Ensure the `Requires at least` and `Requires PHP` headers are present in the `style.css` file.

Follow-up to [46676], which updated `style-rtl.css`, but not `style.scss` or `style.css`.

See #48517.
Built from https://develop.svn.wordpress.org/trunk@47136


git-svn-id: http://core.svn.wordpress.org/trunk@46936 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-30 20:04:05 +00:00
ianbelanger
dae1032531 Bundled Themes: Twenty Twenty add theme support for responsive embeds.
Adds the call to `responsive-embed` theme support in order to fix issues with facebook embeds not being responsive at certain screen widths.

Props williampatton, nielslange.
Fixes #48552.
Built from https://develop.svn.wordpress.org/trunk@47135


git-svn-id: http://core.svn.wordpress.org/trunk@46935 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-30 19:21:07 +00:00
Sergey Biryukov
46a08859d0 Themes: Replace — with – as a separator between Monday and Friday in theme starter content.
The `ndash` standardly is the "through" indicator for showing inclusive dates and numbers, while the `mdash` is an interruptor and used as an aside.

Props mikejdent, garrett-eclipse.
Fixes #48286.
Built from https://develop.svn.wordpress.org/trunk@47134


git-svn-id: http://core.svn.wordpress.org/trunk@46934 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-30 19:17:06 +00:00
ianbelanger
481bbb3128 Bundled Themes: Twenty Twenty content font CSS selector is too important.
This makes the font family selector for `entry-content` less specific and thus easier to override.

Props alexandreb3, larrach, audrasjb.
Fixes #49318.
Built from https://develop.svn.wordpress.org/trunk@47133


git-svn-id: http://core.svn.wordpress.org/trunk@46933 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-30 18:28:07 +00:00
Sergey Biryukov
d3c032bc35 Dashboard: Improve the appearance of "WordPress Events and News" dashboard widget for multi-day events.
If an upcoming event spans over several days, this information is now properly reflected in the widget.

Props imath, casiepa, iandunn, hareesh-pillai, melchoyce, mapk, desrosj, audrasjb, SergeyBiryukov.
Fixes #47798.
Built from https://develop.svn.wordpress.org/trunk@47124


git-svn-id: http://core.svn.wordpress.org/trunk@46924 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 02:19:08 +00:00
Sergey Biryukov
b2ffea836b Docs: Fix typos in wp-admin/includes/class-pclzip.php.
With the upstream library not updated in 10 years since the last time it was merged, it should be safe to treat it as "adopted" rather than external, and make these fixes.

Props passoniate, ottok.
Fixes #49163. See #38464.
Built from https://develop.svn.wordpress.org/trunk@47123


git-svn-id: http://core.svn.wordpress.org/trunk@46923 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:56:04 +00:00
Sergey Biryukov
001ffe81fb Docs: Improve inline comments per the documentation standards.
Includes minor code layout fixes for better readability.

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47122


git-svn-id: http://core.svn.wordpress.org/trunk@46922 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:45:18 +00:00
Sergey Biryukov
e336b24edd Docs: Improve DocBlocks in phpunit/includes/object-cache.php per the documentation standards.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47121


git-svn-id: http://core.svn.wordpress.org/trunk@46921 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:39:04 +00:00
Sergey Biryukov
395ee12145 Docs: Improve comments in js/_enqueues/wp/revisions.js per the documentation standards.
Props passoniate.
Fixes #49177.
Built from https://develop.svn.wordpress.org/trunk@47120


git-svn-id: http://core.svn.wordpress.org/trunk@46920 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:37:04 +00:00
Sergey Biryukov
037a736757 Docs: Improve comments in some wp-admin files per the documentation standards.
Follow-up to [47084].

Props passoniate, apedog.
Fixes #49223, #49227.
Built from https://develop.svn.wordpress.org/trunk@47119


git-svn-id: http://core.svn.wordpress.org/trunk@46919 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:35:08 +00:00
Sergey Biryukov
cfb79b15c3 Coding Standards: Disable WPCS warnings for date_default_timezone_set() and current_time( 'timestamp' ) calls in Date/Time tests.
These calls are intentional and required for the tests.

See #49222.
Built from https://develop.svn.wordpress.org/trunk@47118


git-svn-id: http://core.svn.wordpress.org/trunk@46918 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-28 00:53:05 +00:00
Sergey Biryukov
2c1d3770fa Docs: Fix typo in a comment in js/media/models/attachment.js.
Props wptoolsdev.
Fixes #49303.
Built from https://develop.svn.wordpress.org/trunk@47117


git-svn-id: http://core.svn.wordpress.org/trunk@46917 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-27 14:44:08 +00:00
Sergey Biryukov
50edbd537e Customize: Fix typo in CustomHeader.prototype.initialize() DocBlock in src/js/_enqueues/wp/custom-header.js.
Props ankitmaru.
Fixes #49301.
Built from https://develop.svn.wordpress.org/trunk@47116


git-svn-id: http://core.svn.wordpress.org/trunk@46916 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-27 14:33:05 +00:00
Sergey Biryukov
e65032ff6b Coding Standards: Use strict comparison in wp-admin/user/admin.php.
Apply the case-insensitive network-site comparisons added in [27725] for `wp-admin/network/admin.php` to `wp-admin/user/admin.php` too, for consistency.

Props rimadoshi.
Fixes #49300.
Built from https://develop.svn.wordpress.org/trunk@47115


git-svn-id: http://core.svn.wordpress.org/trunk@46915 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-27 14:30:05 +00:00
Sergey Biryukov
c7bab2b410 Comments: Add In reply to: %s parent comment link to new comment email notifications.
This information was previously available on the Moderate Comment screen in the admin, but was missing from moderation emails.

Props imath, danieltj, andraganescu, galbaras, SergeyBiryukov.
Fixes #43805. See #43429.
Built from https://develop.svn.wordpress.org/trunk@47114


git-svn-id: http://core.svn.wordpress.org/trunk@46914 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-27 04:33:04 +00:00
Sergey Biryukov
b79e042b00 Docs: Remove extra trailing spaces from wp_add_privacy_policy_content() DocBlock to fix WPCS issues, apply minor formatting changes for consistency.
Follow-up to [47112].

See #49282.
Built from https://develop.svn.wordpress.org/trunk@47113


git-svn-id: http://core.svn.wordpress.org/trunk@46913 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-27 01:06:04 +00:00
Andrew Ozz
516629964c Privacy: Cleanup .wp-policy-help CSS remnants and add back-compat when hiding the tutorial content before copying.
Props garrett-eclipse.
Fixes #49282.
Built from https://develop.svn.wordpress.org/trunk@47112


git-svn-id: http://core.svn.wordpress.org/trunk@46912 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-26 23:02:03 +00:00
Sergey Biryukov
1c3b5c9dc8 Comments: Add In reply to %s. prefix to child comments in comments feed.
The prefix includes a link to the parent comment and the name of its author.

Props zodiac1978, imath, SergeyBiryukov.
Fixes #43429.
Built from https://develop.svn.wordpress.org/trunk@47111


git-svn-id: http://core.svn.wordpress.org/trunk@46911 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-26 22:29:06 +00:00
Sergey Biryukov
c9c2ff21f5 Twenty Twenty: Remove unnecessary escaping of get_the_title() in comments.php.
For users with the `unfiltered_html` capability, titles can contain legitimate markup.

The title is filtered on saving, so the content in the database is considered safe.

Props kjellr, joyously, peterwilsoncc.
Fixes #49190.
Built from https://develop.svn.wordpress.org/trunk@47110


git-svn-id: http://core.svn.wordpress.org/trunk@46910 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-25 22:06:07 +00:00
Sergey Biryukov
b8d10d8b63 Docs: Improve documentation for add_user_to_blog(), add_existing_user_to_blog(), and add_new_user_to_blog().
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47109


git-svn-id: http://core.svn.wordpress.org/trunk@46909 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-24 17:20:07 +00:00
Andrea Fercia
6b4368669d Toolbar: Remove leftover @since notations after [46678].
See #19647.

Built from https://develop.svn.wordpress.org/trunk@47108


git-svn-id: http://core.svn.wordpress.org/trunk@46908 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-23 12:59:06 +00:00
Sergey Biryukov
c67b2c235a Cache API: Remove WP_Object_Cache::__destruct() and wpdb::__destruct().
Originally added in [4686], these constructor/destructor pairings were designed to prevent the objects from being destroyed before shutdown, when output buffers are flushed.

A deeper investigation reveals that this approach didn't quite work as expected and was later made redundant by introducing `wp_ob_end_flush_all()` in [5462].

Props wonderboymusic, nacin, Mte90, SergeyBiryukov.
Fixes #21402.
Built from https://develop.svn.wordpress.org/trunk@47107


git-svn-id: http://core.svn.wordpress.org/trunk@46907 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-23 00:27:05 +00:00
jorgefilipecosta
48299521c6 Block Editor: Update WordPress Packages.
The following package versions were changed:
@wordpress/a11y: 2.5.1 -> 2.6.0
@wordpress/annotations: 1.9.0 -> 1.10.0
@wordpress/api-fetch: 3.8.0 -> 3.9.0
@wordpress/blob: 2.5.1 -> 2.6.0
@wordpress/block-directory: 1.2.0 -> 1.3.0
@wordpress/block-editor: 3.4.0 -> 3.5.0
@wordpress/block-library: 2.11.0 -> 2.12.0
@wordpress/blocks: 6.9.0 -> 6.10.0
@wordpress/components: 8.5.0 -> 9.0.0
@wordpress/compose: 3.9.0 -> 3.10.0
@wordpress/core-data: 2.9.0 -> 2.10.0
@wordpress/data: 4.11.0 -> 4.12.0
@wordpress/data-controls: 1.5.0 -> 1.6.0
@wordpress/dom: 2.6.0 -> 2.7.0
@wordpress/dom-ready: 2.5.1 -> 2.6.0
@wordpress/e2e-test-utils: 4.0.0 -> 4.1.0
@wordpress/edit-post: 3.10.0 -> 3.11.0
@wordpress/editor: 9.9.0 -> 9.10.0
@wordpress/format-library: 1.11.0 -> 1.12.0
@wordpress/i18n: 3.7.0 -> 3.8.0
@wordpress/is-shallow-equal: 1.6.1 -> 1.7.0
@wordpress/keycodes: 2.7.0 -> 2.8.0
@wordpress/list-reusable-blocks: 1.10.0 -> 1.11.0
@wordpress/media-utils: 1.4.0 -> 1.5.0
@wordpress/notices: 1.10.0 -> 1.11.0
@wordpress/nux: 3.9.0 -> 3.10.0
@wordpress/plugins: 2.9.0 -> 2.10.0
@wordpress/priority-queue: 1.3.1 -> 1.4.0
@wordpress/rich-text: 3.9.0 -> 3.10.0
@wordpress/scripts: 6.1.1 -> 6.2.0
@wordpress/server-side-render: 1.5.0 -> 1.6.0
@wordpress/viewport: 2.10.0 -> 2.11.0
The following package was added:
@wordpress/keyboard-shortcuts

Props gziolo.
Fixes #49204.
Built from https://develop.svn.wordpress.org/trunk@47106


git-svn-id: http://core.svn.wordpress.org/trunk@46906 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 22:06:21 +00:00
iandunn
2974f78157 Multisite: Add $context parameter to switch_blog action.
The action is fired by both `switch_to_blog()` and `restore_current_blog()`, and previously it was difficult for callback functions to determine which function had fired it.

Props SergeyBiryukov, johnbillion, jeremyfelt.
Fixes #49265.

Built from https://develop.svn.wordpress.org/trunk@47105


git-svn-id: http://core.svn.wordpress.org/trunk@46905 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 20:53:05 +00:00
Sergey Biryukov
f34eef4437 Docs: Expand @return value description for wp_loginout(), wp_register(), get_calendar().
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47104


git-svn-id: http://core.svn.wordpress.org/trunk@46904 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 00:57:03 +00:00
Sergey Biryukov
6cf32058ff Docs: Expand @return description for the_terms().
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47103


git-svn-id: http://core.svn.wordpress.org/trunk@46903 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 00:41:06 +00:00
Sergey Biryukov
cfa3dc8ee8 Docs: Correct @return value for parent_dropdown().
Follow-up to [47100].

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47102


git-svn-id: http://core.svn.wordpress.org/trunk@46902 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 00:33:04 +00:00
Sergey Biryukov
c3f9af4f00 Docs: Adjust documentation for some pre_* filters for consistency.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47101


git-svn-id: http://core.svn.wordpress.org/trunk@46901 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 00:25:04 +00:00
Sergey Biryukov
eb513c5ac8 Docs: Adjust @return value of parent_dropdown() for consistency with other dropdown functions.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47100


git-svn-id: http://core.svn.wordpress.org/trunk@46900 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 00:22:03 +00:00
Sergey Biryukov
381df97419 Docs: Correct @return value for update_core() and Core_Upgrader::upgrade().
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47099


git-svn-id: http://core.svn.wordpress.org/trunk@46899 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-22 00:19:04 +00:00
Sergey Biryukov
46dd0a79f6 Date/Time: In wp_maybe_decline_date(), add support for a range of days, e.g. February 21–23.
A potential use case is displaying multi-day events in the WordPress Events and News dashboard widget.

See #47798, #48934.
Built from https://develop.svn.wordpress.org/trunk@47098


git-svn-id: http://core.svn.wordpress.org/trunk@46898 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-21 23:48:04 +00:00
Sergey Biryukov
95f5cecd77 Docs: Expand @return value description for wp_nav_menu().
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47097


git-svn-id: http://core.svn.wordpress.org/trunk@46897 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-21 20:13:05 +00:00
Sergey Biryukov
dd79e6e107 Docs: Correct DocBlock formatting for filters accepting the $parsed_args parameter.
Follow-up to [45667].

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47096


git-svn-id: http://core.svn.wordpress.org/trunk@46896 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-21 15:41:04 +00:00
Sergey Biryukov
185e36d428 I18N: Merge duplicate "you must be logged in to comment" strings.
Props ramiy.
Fixes #49251.
Built from https://develop.svn.wordpress.org/trunk@47095


git-svn-id: http://core.svn.wordpress.org/trunk@46895 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-21 14:52:06 +00:00
Sergey Biryukov
6730b3f716 I18N: Synchronize MediaElement.js translation strings with the currently bundled version.
Some strings were previously removed in [43345] and accidentally reintroduced in [44163].

Props ramiy.
Fixes #49249. See #42139, #37453.
Built from https://develop.svn.wordpress.org/trunk@47094


git-svn-id: http://core.svn.wordpress.org/trunk@46894 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-21 02:21:05 +00:00
Sergey Biryukov
60c651ad6a I18N: Add missing placeholders to some translators comments in wp-admin.
Props ramiy.
Fixes #49248.
Built from https://develop.svn.wordpress.org/trunk@47093


git-svn-id: http://core.svn.wordpress.org/trunk@46893 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-20 15:43:04 +00:00
Sergey Biryukov
c946a71d9d I18N: Correct translator comment in wp-admin/options-permalink.php.
Props ramiy.
Fixes #49247.
Built from https://develop.svn.wordpress.org/trunk@47092


git-svn-id: http://core.svn.wordpress.org/trunk@46892 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-20 15:10:04 +00:00
Sergey Biryukov
cf249b07ed I18N: Merge duplicate %1$s is not of type %2$s strings in rest_validate_value_from_schema().
Props ramiy.
Fixes #49244.
Built from https://develop.svn.wordpress.org/trunk@47091


git-svn-id: http://core.svn.wordpress.org/trunk@46891 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-20 14:44:06 +00:00
Sergey Biryukov
1adca958e3 I18N: Remove unnecessary HTML from "Active:" strings in wp-admin/themes.php.
Follow-up to [45435].

Props ramiy.
Fixes #49243.
Built from https://develop.svn.wordpress.org/trunk@47090


git-svn-id: http://core.svn.wordpress.org/trunk@46890 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-20 14:27:04 +00:00
Sergey Biryukov
d5be8f0635 I18N: Correct translator comments in WP_Users_List_Table::get_views() to provide information about each placeholder.
Props ramiy.
Fixes #49242.
Built from https://develop.svn.wordpress.org/trunk@47089


git-svn-id: http://core.svn.wordpress.org/trunk@46889 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-20 14:08:05 +00:00
Sergey Biryukov
2900bb8ea7 Docs: Update links to https://secure.php.net/, they now redirect to https://www.php.net/.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47088


git-svn-id: http://core.svn.wordpress.org/trunk@46888 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-20 03:14:06 +00:00
Sergey Biryukov
f9b0dfbb8b Docs: Correct description for shortcode_atts_{$shortcode} filter.
Props glebkema.
Fixes #49225.
Built from https://develop.svn.wordpress.org/trunk@47087


git-svn-id: http://core.svn.wordpress.org/trunk@46887 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-19 13:41:08 +00:00
Sergey Biryukov
bb5765e951 Mail: Remove angle brackets from password reset URL in emails sent by retrieve_password() and wp_new_user_notification().
The brackets were originally added in [16285] per W3C recommendation in https://www.w3.org/Addressing/URL/5.1_Wrappers.html to avoid wrapping the URL across multiple lines in plain text in older email clients.

This doesn't seem like a common issue in modern email clients, and the current implementation causes more issues than it solves. Since the URL is on a line by itself, it should not require any delimiters.

The URL in recovery mode email introduced in [44973] doesn't have angle brackets, so it's time to retire them in password reset email too if they're not used consistently.

Props donmhico, Otto42, sproutchris, iandunn, dd32, DaveWP196, sebastian.pisula, tommix, sablednah, julian.kimmig, Rahe, clayisland, arenddeboer, nicole2292, nagoke, squarecandy, eatingrules, SergeyBiryukov.
Fixes #21095, #23578, #44589.
Built from https://develop.svn.wordpress.org/trunk@47086


git-svn-id: http://core.svn.wordpress.org/trunk@46886 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-18 02:32:06 +00:00
Sergey Biryukov
89f5d3dd0c Networks and Sites: Clarify the recommendation to remove the www prefix from the site domain before creating a network.
The `siteurl` option reference was not quite clear, and the string actually refers to the domain name, not the full URL.

Props kharisblank, tobifjellner, ramiy.
Fixes #49214.
Built from https://develop.svn.wordpress.org/trunk@47085


git-svn-id: http://core.svn.wordpress.org/trunk@46885 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-18 01:15:04 +00:00
Sergey Biryukov
053a9cd5b8 Docs: Improve comments in some wp-admin files per the documentation standards.
Props passoniate.
Fixes #49215, #49216.
Built from https://develop.svn.wordpress.org/trunk@47084


git-svn-id: http://core.svn.wordpress.org/trunk@46884 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-18 00:54:04 +00:00
Sergey Biryukov
1cfc32af58 Coding Standards: Remove unnecessary // phpcs:ignore instances in WP_Debug_Data.
`WP_Theme::__get()` accepts `Name`, `Version`, and `Author` theme properties in lower case too.

Additionally, remove one short ternary instance, not allowed per the coding standards.

See #49222.
Built from https://develop.svn.wordpress.org/trunk@47083


git-svn-id: http://core.svn.wordpress.org/trunk@46883 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-18 00:26:06 +00:00
Sergey Biryukov
0f47f2b9e5 Widgets: Remove extra padding from number inputs in Recent Posts and Recent Comments widgets.
Props marcio-zebedeu, audrasjb, SergeyBiryukov.
Fixes #49195.
Built from https://develop.svn.wordpress.org/trunk@47082


git-svn-id: http://core.svn.wordpress.org/trunk@46882 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-17 13:57:03 +00:00
Sergey Biryukov
82f41c5afc Date/Time: Add some basic tests for current_time().
Props pbearne, talldanwp, SergeyBiryukov.
Fixes #34378.
Built from https://develop.svn.wordpress.org/trunk@47081


git-svn-id: http://core.svn.wordpress.org/trunk@46881 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-17 02:52:05 +00:00
Sergey Biryukov
d84c987e16 Tests: Replace date() with gmdate() in WP_Test_REST_Posts_Controller tests.
Follow-up to [45424], [46252].

See #46438, #44491, #39953.
Built from https://develop.svn.wordpress.org/trunk@47080


git-svn-id: http://core.svn.wordpress.org/trunk@46880 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-17 02:04:04 +00:00
Sergey Biryukov
5c358b8f19 Tests: Update the wp_maybe_decline_date() tests for [47078].
See #48934.
Built from https://develop.svn.wordpress.org/trunk@47079


git-svn-id: http://core.svn.wordpress.org/trunk@46879 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-17 01:16:04 +00:00
Sergey Biryukov
a370d1a9c0 Date/Time: Pass the date format to wp_maybe_decline_date().
This ensures that the function has enough context to determine the necessity of replacing the month name with the correct form in locales that require it.

Props SergeyBiryukov, Rarst.
Fixes #48934.
Built from https://develop.svn.wordpress.org/trunk@47078


git-svn-id: http://core.svn.wordpress.org/trunk@46878 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-17 01:12:04 +00:00
Sergey Biryukov
e884aca67b Tests: Revert [47076], this should have been committed with the related changes to the function.
Built from https://develop.svn.wordpress.org/trunk@47077


git-svn-id: http://core.svn.wordpress.org/trunk@46877 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-17 01:10:04 +00:00
Sergey Biryukov
c883c65e3c Tests: Move wp_maybe_decline_date() tests to the date directory.
See #48934.
Built from https://develop.svn.wordpress.org/trunk@47076


git-svn-id: http://core.svn.wordpress.org/trunk@46876 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-17 00:56:07 +00:00
Sergey Biryukov
45286c5bb3 Accessibility: Login and Registration: Add a role="main" landmark to the container div in wp-signup.php.
Props SteelWagstaff, audrasjb.
Fixes #48657.
Built from https://develop.svn.wordpress.org/trunk@47075


git-svn-id: http://core.svn.wordpress.org/trunk@46875 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-16 03:44:05 +00:00
Sergey Biryukov
06f90e098a Login and Registration: Remove duplicate <label> tag from show_blog_form() in wp-signup.php.
Props vaishalipanchal, audrasjb.
Fixes #49174.
Built from https://develop.svn.wordpress.org/trunk@47074


git-svn-id: http://core.svn.wordpress.org/trunk@46874 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-16 00:34:05 +00:00
Sergey Biryukov
691adde1e6 Date/Time: Use wp_date() to display the correct time of the next DST transition in Timezone setting on General Settings screen.
Props Rarst, autotutorial.
Fixes #49038.
Built from https://develop.svn.wordpress.org/trunk@47073


git-svn-id: http://core.svn.wordpress.org/trunk@46873 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-16 00:28:06 +00:00
Sergey Biryukov
3e68a63e6a Editor: Correct vertical alignment for "Published on" month dropdown in Classic Editor.
Props pratik-jain, justinahinon, audrasjb.
Fixes #49115.
Built from https://develop.svn.wordpress.org/trunk@47072


git-svn-id: http://core.svn.wordpress.org/trunk@46872 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-15 18:31:07 +00:00
Sergey Biryukov
57fbd3c847 File Editor: Remove extra padding on submit button for "Select plugin/theme to edit" dropdown on smaller screens.
Props passoniate.
Fixes #49197.
Built from https://develop.svn.wordpress.org/trunk@47071


git-svn-id: http://core.svn.wordpress.org/trunk@46871 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-15 00:23:07 +00:00
Sergey Biryukov
569ff9dd27 Upgrade/Install: Correct vertical alignment for "Continue" button on language selection during the install process.
Props garrett-eclipse, audrasjb.
Fixes #49018.
Built from https://develop.svn.wordpress.org/trunk@47070


git-svn-id: http://core.svn.wordpress.org/trunk@46870 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-14 01:11:03 +00:00
Sergey Biryukov
10ae398727 Site Health: Avoid "Undefined property" PHP notices in wp_dashboard_site_health() when the status result transient does not exist yet.
Props dlh for initial patch.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47069


git-svn-id: http://core.svn.wordpress.org/trunk@46869 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-13 17:27:06 +00:00
Sergey Biryukov
4a9c0e35e1 Cron API: Use WEEK_IN_SECONDS constant for the weekly schedule added in [47062].
Props afercia.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47068


git-svn-id: http://core.svn.wordpress.org/trunk@46868 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-13 17:05:07 +00:00
Sergey Biryukov
f18b173674 Networks and Sites: Use warning styles for 'Caution' and 'Warning' messages during Multisite installation.
Props dlh.
Fixes #49186.
Built from https://develop.svn.wordpress.org/trunk@47067


git-svn-id: http://core.svn.wordpress.org/trunk@46867 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-13 17:00:06 +00:00
Sergey Biryukov
9fa4cce9c2 Docs: Correct description for show_in_admin_all_list and show_in_admin_status_list arguments of register_post_status().
Props audrasjb.
Fixes #49180.
Built from https://develop.svn.wordpress.org/trunk@47066


git-svn-id: http://core.svn.wordpress.org/trunk@46866 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-13 00:50:02 +00:00
Sergey Biryukov
fa2f6e0644 Docs: Improve documentation for wp_save_image_file() and related functions.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47065


git-svn-id: http://core.svn.wordpress.org/trunk@46865 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-12 16:56:05 +00:00
Sergey Biryukov
810a243f2d Tests: In Tests_Site_Health, create a WP_Site_Health instance before clearing the cron array, as the constructor schedules its own task now.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47064


git-svn-id: http://core.svn.wordpress.org/trunk@46864 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-12 14:18:03 +00:00
Sergey Biryukov
2c4480958b Site Health: Introduce Site Health Status dashboard widget.
The widget informs administrators of any potential issues that should be addressed to improve the performance or security of their website, and directs them to the Site Health screen for more details.

Props Clorith, hedgefield, guddu1315.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47063


git-svn-id: http://core.svn.wordpress.org/trunk@46863 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-12 13:33:05 +00:00
Sergey Biryukov
26ce3c9f19 Cron API: Add a new cron schedule for weekly events.
Props Clorith.
See #47606.
Built from https://develop.svn.wordpress.org/trunk@47062


git-svn-id: http://core.svn.wordpress.org/trunk@46862 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-12 11:20:04 +00:00
Sergey Biryukov
f8a5ae6b93 Upgrade/Install: Remove the suggestion for users to skip a minor update to keep their current translation.
With the introduction of asynchronous translation updates in WordPress 3.7+, the suggestion is no longer relevant.

Props casiepa, danieltj, tobifjellner, netweb.
Fixes #43242.
Built from https://develop.svn.wordpress.org/trunk@47061


git-svn-id: http://core.svn.wordpress.org/trunk@46861 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-12 02:24:03 +00:00
Sergey Biryukov
dd4d98a368 Docs: In various @return tags, list the expected type first, instead of false.
Follow-up to [46696].

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47060


git-svn-id: http://core.svn.wordpress.org/trunk@46860 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-11 18:32:05 +00:00
Sergey Biryukov
2294d65753 Docs: Synchronize @return descriptions for ::handle_row_actions() methods in list tables.
Make sure `WP_Comments_List_Table::handle_row_actions()` and `WP_MS_Sites_List_Table::handle_row_actions()` return a string, for consistency with other classes.

See #49170, #48303.
Built from https://develop.svn.wordpress.org/trunk@47059


git-svn-id: http://core.svn.wordpress.org/trunk@46859 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-11 17:59:04 +00:00
Sergey Biryukov
d469aa8162 Docs: Correct @return description for WP_List_Table::handle_row_actions().
Props pbiron.
Fixes #49170.
Built from https://develop.svn.wordpress.org/trunk@47058


git-svn-id: http://core.svn.wordpress.org/trunk@46858 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-11 17:57:03 +00:00
Sergey Biryukov
6a3deacf86 Docs: Correct @return type for Theme_Upgrader::check_parent_theme_filter().
Props diddledan.
Fixes #48570.
Built from https://develop.svn.wordpress.org/trunk@47057


git-svn-id: http://core.svn.wordpress.org/trunk@46857 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-11 02:46:05 +00:00
Sergey Biryukov
77aa5d1604 Docs: Remove a reference to WordPress 2.7 from readme.html.
Props afercia, donmhico.
Fixes #47963.
Built from https://develop.svn.wordpress.org/trunk@47056


git-svn-id: http://core.svn.wordpress.org/trunk@46856 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-10 14:05:05 +00:00
Sergey Biryukov
a94ed9baf3 Docs: Remove @return void from widget DocBlocks.
Per the documentation standards, it should not be used outside of the default bundled themes.

See #48303.
Built from https://develop.svn.wordpress.org/trunk@47055


git-svn-id: http://core.svn.wordpress.org/trunk@46855 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-10 00:30:05 +00:00
Sergey Biryukov
d784ebbcb4 Coding Standards: Use strict comparison and Yoda conditions in the root directory files.
Props pikamander2.
Fixes #48965.
Built from https://develop.svn.wordpress.org/trunk@47054


git-svn-id: http://core.svn.wordpress.org/trunk@46854 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-09 00:55:05 +00:00
desrosj
a24f5ccd1f Bundled Themes: Remove duplicate font-size property in Twenty Twenty.
Props ankitmaru.
Fixes #49015.


Built from https://develop.svn.wordpress.org/trunk@47053


git-svn-id: http://core.svn.wordpress.org/trunk@46853 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-08 16:50:04 +00:00
Sergey Biryukov
cef48881f0 Docs: Correct alphabetic order of parameters in WP_Query::parse_query() DocBlock.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47052


git-svn-id: http://core.svn.wordpress.org/trunk@46852 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-08 12:10:04 +00:00
jorgefilipecosta
80ce372761 Block Editor: Update WordPress Packages.
Updated packages:
@wordpress/annotations: 1.7.2 -> 1.9.0
@wordpress/api-fetch: 3.6.4 -> 3.8.0
@wordpress/block-directory: 1.0.5 -> 1.2.0
@wordpress/block-editor: 3.2.5 -> 3.4.0
@wordpress/block-library: 2.9.6 -> 2.11.0
@wordpress/blocks: 6.7.2 -> 6.9.0
@wordpress/components: 8.3.2 -> 8.5.0
@wordpress/compose: 3.7.2 -> 3.9.0
@wordpress/core-data: 2.7.5 -> 2.9.0
@wordpress/data: 4.9.2 -> 4.11.0
@wordpress/data-controls: 1.3.4 -> 1.5.0
@wordpress/date: 3.5.0 -> 3.7.0
@wordpress/dom: 2.5.2 -> 2.6.0
@wordpress/e2e-test-utils: 3.0.0 -> 4.0.0
@wordpress/edit-post: 3.8.6 -> 3.10.0
@wordpress/editor: 9.7.6 -> 9.9.0
@wordpress/element: 2.8.2 -> 2.10.0
@wordpress/escape-html: 1.5.1 -> 1.6.0
@wordpress/format-library: 1.9.5 -> 1.11.0
@wordpress/i18n: 3.6.1 -> 3.7.0
@wordpress/keycodes: 2.6.2 -> 2.7.0
@wordpress/list-reusable-blocks: 1.8.4 -> 1.10.0
@wordpress/media-utils: 1.2.4 -> 1.4.0
@wordpress/notices: 1.8.2 -> 1.10.0
@wordpress/nux: 3.7.2 -> 3.9.0
@wordpress/plugins: 2.7.2 -> 2.9.0
@wordpress/rich-text: 3.7.2 -> 3.9.0
@wordpress/scripts: 6.0.0 -> 6.1.1
@wordpress/server-side-render: 1.3.4 -> 1.5.0
@wordpress/shortcode: 2.4.1 -> 2.5.0
@wordpress/token-list: 1.6.1 -> 1.8.0
@wordpress/url: 2.8.2 -> 2.9.0
@wordpress/viewport: 2.8.2 -> 2.10.0

Props gziolo, youknowriad.
Fixes #49142.
Built from https://develop.svn.wordpress.org/trunk@47051


git-svn-id: http://core.svn.wordpress.org/trunk@46851 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-08 11:57:23 +00:00
Sergey Biryukov
ea6e0cc3ca Coding Standards: Use Yoda conditions in wp-includes/rest-api/endpoints/class-wp-rest-users-controller.php.
Props jenilk.
Fixes #49150.
Built from https://develop.svn.wordpress.org/trunk@47050


git-svn-id: http://core.svn.wordpress.org/trunk@46850 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-08 11:32:02 +00:00
Sergey Biryukov
967f43a6cb Docs: Indicate that load_script_textdomain_relative_path filter value can be false.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47049


git-svn-id: http://core.svn.wordpress.org/trunk@46849 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-08 00:27:04 +00:00
gziolo
572f1725d9 Build Tools: do not include assets for JS dependencies that do not exist.
This is a follow-up for #48154, where we started including *.asset.php files to declare package dependencies.
This works well but creates warnings in environments where the package does not exist because WordPress was not fully built.

Props jeherve, swissspidy.

Fixes #49144.


Built from https://develop.svn.wordpress.org/trunk@47048


git-svn-id: http://core.svn.wordpress.org/trunk@46848 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-07 15:28:05 +00:00
Sergey Biryukov
d3d630c98a Site Health: Make sure the "Copied!" text is vertically centered to the "Copy site info to clipboard" button.
Props garrett-eclipse.
Fixes #49139.
Built from https://develop.svn.wordpress.org/trunk@47047


git-svn-id: http://core.svn.wordpress.org/trunk@46847 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-07 00:09:04 +00:00
Sergey Biryukov
ce48d7502c REST API: Display the actual conflicting value in addition to the taxonomy name in the _doing_it_wrong() message for a conflicting rest_base or name property.
Follow-up to [47037] and [47045].

Props TimothyBlynJacobs.
See #48401.
Built from https://develop.svn.wordpress.org/trunk@47046


git-svn-id: http://core.svn.wordpress.org/trunk@46846 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-06 17:09:04 +00:00
Sergey Biryukov
a540d748d3 REST API: Display the taxonomy name in the _doing_it_wrong() message for a conflicting rest_base or name property, to match the translator comment.
Follow-up to [47037].

See #48401.
Built from https://develop.svn.wordpress.org/trunk@47045


git-svn-id: http://core.svn.wordpress.org/trunk@46845 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-06 16:47:02 +00:00
Sergey Biryukov
28639fc8d5 I18N: Replace rest_authentication_errors filter name with a placeholder in a translatable string.
Follow-up to [38947] and [40038].

See #38446.
Built from https://develop.svn.wordpress.org/trunk@47044


git-svn-id: http://core.svn.wordpress.org/trunk@46844 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-06 16:21:04 +00:00
Sergey Biryukov
667f26b3af I18N: Replace php.ini, post_max_size, and upload_max_filesize with placeholders in "File is empty" error message.
Props ramiy.
Fixes #48868.
Built from https://develop.svn.wordpress.org/trunk@47043


git-svn-id: http://core.svn.wordpress.org/trunk@46843 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-06 16:16:03 +00:00
Dominik Schilling
918dead27e Docs: Remove duplicate inline comment in wp_mail().
See [5639].
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47042


git-svn-id: http://core.svn.wordpress.org/trunk@46842 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-06 14:51:05 +00:00
Sergey Biryukov
0be749362a Docs: Improve documentation for tests/phpunit/includes/testcase-ajax.php.
Props andizer, SergeyBiryukov.
Fixes #47568.
Built from https://develop.svn.wordpress.org/trunk@47041


git-svn-id: http://core.svn.wordpress.org/trunk@46841 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-05 15:33:00 +00:00
Dominik Schilling
c89dab8c98 Media: After [46375], enable JavaScript translations for the media-views script.
See #49134.
Built from https://develop.svn.wordpress.org/trunk@47040


git-svn-id: http://core.svn.wordpress.org/trunk@46840 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-05 13:11:04 +00:00
Sergey Biryukov
6a3a0b519c Docs: Fix typo in media_post_single_attachment_fields_to_edit() description.
Props mukesh27.
Fixes #49131.
Built from https://develop.svn.wordpress.org/trunk@47039


git-svn-id: http://core.svn.wordpress.org/trunk@46839 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-04 18:00:06 +00:00
Sergey Biryukov
7ad56f1237 Coding Standards: Add missing braces to if conditions in js/_enqueues/wp/customize/base.js.
Props ankitmaru.
Fixes #49122.
Built from https://develop.svn.wordpress.org/trunk@47038


git-svn-id: http://core.svn.wordpress.org/trunk@46838 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-04 01:28:05 +00:00
K. Adam White
08f53ef906 REST API: Issue doing_it_wrong if a taxonomy's specified rest_base is already in use by a different resource.
Props fgiannar, TimothyBlynJacobs, kingkool68, SergeyBiryukov.
Fixes #48401.


Built from https://develop.svn.wordpress.org/trunk@47037


git-svn-id: http://core.svn.wordpress.org/trunk@46837 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-03 19:24:03 +00:00
K. Adam White
7660fcda61 REST API: Short-circuit comment controller permissions check if commented-upon post type does not exist.
Props imani3011, dragosh635, subrataemfluence, timothyblynjacobs.
Fixes #42238.


Built from https://develop.svn.wordpress.org/trunk@47036


git-svn-id: http://core.svn.wordpress.org/trunk@46836 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-03 18:44:03 +00:00
gziolo
355c05ea71 Build Tools: Integrate DependencyExtractionWebpackPlugin in the JS build.
This patch integrates DependencyExtractionWebpackPlugin which was battle-tested in Gutenberg. 

This will greatly simplify the process of upgrading npm packages which change after every Gutenberg release. It might even useful during the WordPress release cycle as we might need to publish more often as we discover critical bugs and regressions.

Props jonsurrell, adamsilverstein, youknowriad, ocean90, netweb.

Fixes #48154. 


Built from https://develop.svn.wordpress.org/trunk@47035


git-svn-id: http://core.svn.wordpress.org/trunk@46835 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-03 13:17:24 +00:00
Sergey Biryukov
9bec6f1e54 REST API: Synchronize permission checks in ::get_items_permissions_check() methods for post types, post statuses, and users:
* Only query post types with `'show_in_rest' => true` instead of looping over all post types and checking the `show_in_rest` property separately.
* Return from the `foreach()` loop as soon as the permission check succeeded.

Props pbiron, TimothyBlynJacobs, SergeyBiryukov.
Fixes #49118.
Built from https://develop.svn.wordpress.org/trunk@47034


git-svn-id: http://core.svn.wordpress.org/trunk@46834 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-03 02:28:03 +00:00
Sergey Biryukov
ba033e96ef Link Manager: Use a strict in_array() check in wp-links-opml.php.
Props dkarfa.
Fixes #49106.
Built from https://develop.svn.wordpress.org/trunk@47033


git-svn-id: http://core.svn.wordpress.org/trunk@46833 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-03 01:14:02 +00:00
Sergey Biryukov
523bf256ef Docs: Synchronize "Default empty array" notes for $args parameter in get_comment_text() and comment_text().
Props denisco.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47032


git-svn-id: http://core.svn.wordpress.org/trunk@46832 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-02 19:22:03 +00:00
Sergey Biryukov
8ec3da8a25 Site Health: Fix typo in a variable name in js/_enqueues/admin/site-health.js.
Props nickylimjj.
Fixes #49112.
Built from https://develop.svn.wordpress.org/trunk@47031


git-svn-id: http://core.svn.wordpress.org/trunk@46831 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-02 12:11:02 +00:00
Sergey Biryukov
9571033894 Coding Standards: Move assignment out of condition in js/media/controllers/library.js.
Props ankitmaru.
Fixes #49108.
Built from https://develop.svn.wordpress.org/trunk@47030


git-svn-id: http://core.svn.wordpress.org/trunk@46830 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-02 12:07:02 +00:00
Sergey Biryukov
d3a14b7719 Coding Standards: Move assignment out of condition in js/media/views/settings.js.
Props ankitmaru.
Fixes #49107.
Built from https://develop.svn.wordpress.org/trunk@47029


git-svn-id: http://core.svn.wordpress.org/trunk@46829 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-02 12:02:02 +00:00
Sergey Biryukov
f2e464f8c1 Coding Standards: Use strict comparison in wp-comments-post.php.
Props dkarfa.
Fixes #49105.
Built from https://develop.svn.wordpress.org/trunk@47028


git-svn-id: http://core.svn.wordpress.org/trunk@46828 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-02 11:42:01 +00:00
Sergey Biryukov
b9353dbf70 Coding Standards: Use strict comparison and Yoda conditions in wp-includes/widgets.php.
Props jenilk.
Fixes #49104.
Built from https://develop.svn.wordpress.org/trunk@47027


git-svn-id: http://core.svn.wordpress.org/trunk@46827 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-02 11:37:05 +00:00
Sergey Biryukov
3fe8bdfca7 Happy New Year!
Update copyright year to 2020 in bundled themes' `readme.txt`.
Built from https://develop.svn.wordpress.org/trunk@47026


git-svn-id: http://core.svn.wordpress.org/trunk@46826 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-01 03:53:01 +00:00
Sergey Biryukov
c856ffcd0a Happy New Year!
Update copyright year to 2020 in `license.txt`.
Built from https://develop.svn.wordpress.org/trunk@47025


git-svn-id: http://core.svn.wordpress.org/trunk@46825 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-01 02:19:06 +00:00
Sergey Biryukov
6357cae029 Docs: Fix typo in _crop_image_resource() DocBlock.
Props mukesh27.
Fixes #49103.
Built from https://develop.svn.wordpress.org/trunk@47024


git-svn-id: http://core.svn.wordpress.org/trunk@46824 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-31 12:34:01 +00:00
Sergey Biryukov
a2f5c24d36 Docs: Add missing descriptions and @return tags for _WP_Editors::get_mce_locale() and ::get_baseurl().
Props adnan.limdi.
Fixes #41869.
Built from https://develop.svn.wordpress.org/trunk@47023


git-svn-id: http://core.svn.wordpress.org/trunk@46823 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-31 01:31:02 +00:00
Sergey Biryukov
7174c2a0c7 Docs: Add missing @since tags for wp-includes/class-wp-editor.php.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47022


git-svn-id: http://core.svn.wordpress.org/trunk@46822 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-31 01:25:03 +00:00
Sergey Biryukov
09e7a72ec2 Docs: Fix typo in .env file description.
Props mujuonly, dkarfa.
Fixes #49095.
Built from https://develop.svn.wordpress.org/trunk@47021


git-svn-id: http://core.svn.wordpress.org/trunk@46821 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-30 13:48:03 +00:00
Sergey Biryukov
fef26f8d1f Coding Standards: Fix WPCS issue in [47019].
See #49091.
Built from https://develop.svn.wordpress.org/trunk@47020


git-svn-id: http://core.svn.wordpress.org/trunk@46820 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-29 22:32:00 +00:00
Sergey Biryukov
7590296984 Twenty Twenty: Remove extra space from arrow-down-circled icon name in TwentyTwenty_SVG_Icons::$ui_icons.
Props kitchin.
Fixes #49091.
Built from https://develop.svn.wordpress.org/trunk@47019


git-svn-id: http://core.svn.wordpress.org/trunk@46819 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-29 20:45:06 +00:00
Sergey Biryukov
d858656023 Bootstrap/Load: Make handling the /favicon.ico requests more flexible.
Previously, `wp_favicon_request()` was introduced in [13205] to avoid a performance hit of serving a full 404 page on every favicon request.

While working as intended, that implementation did not provide a way for theme or plugin authors to manage the behavior of favicon requests.

This changeset implements the following logic (only applied if WordPress is installed in the root directory):

* If there is a Site Icon set in Customizer, redirect `/favicon.ico` requests to that icon.
* Otherwise, use the WordPress logo as a default icon.
* If a physical `/favicon.ico` file exists, do nothing, let the server handle the request.

Handling `/favicon.ico` is now more consistent with handling `/robots.txt` requests.

New functions and hooks:

* Introduce `is_favicon()` conditional tag to complement `is_robots()`.
* Introduce `do_favicon` action to complement `do_robots` and use it in template loader.
* Introduce `do_favicon()` function, hooked to the above action by default, to complement `do_robots()`.
* Introduce `do_faviconico` action to complement `do_robotstxt`, for plugins to override the default behavior.
* Mark `wp_favicon_request()` as deprecated in favor of `do_favicon()`.

Props jonoaldersonwp, birgire, joostdevalk, mukesh27, SergeyBiryukov.
Fixes #47398.
Built from https://develop.svn.wordpress.org/trunk@47018


git-svn-id: http://core.svn.wordpress.org/trunk@46818 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-28 21:20:04 +00:00
Sergey Biryukov
c546aa36ec Docs: Improve @return description for wp_update_comment() and WP_UnitTest_Factory_For_Comment::update_object().
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47017


git-svn-id: http://core.svn.wordpress.org/trunk@46817 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-27 00:30:02 +00:00
Sergey Biryukov
7970e62c06 Coding Standards: Fix WPCS issue in [47015].
See #49082.
Built from https://develop.svn.wordpress.org/trunk@47016


git-svn-id: http://core.svn.wordpress.org/trunk@46816 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-26 15:53:02 +00:00
Sergey Biryukov
7c2275dfe4 Docs: Fix typo in wp_dashboard_cached_rss_widget() documentation.
Props mukesh27.
Fixes #49082.
Built from https://develop.svn.wordpress.org/trunk@47015


git-svn-id: http://core.svn.wordpress.org/trunk@46815 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-26 14:42:03 +00:00
Sergey Biryukov
a814d6e363 Tests: Set network_id instead of site_id in WP_UnitTest_Factory_For_Blog defaults.
Follow-up to [47011], [47013].

See #47195.
Built from https://develop.svn.wordpress.org/trunk@47014


git-svn-id: http://core.svn.wordpress.org/trunk@46814 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-26 00:27:03 +00:00
Sergey Biryukov
5e236248e4 Tests: Update legacy arguments passed to WP_UnitTest_Factory_For_Blog::create_object().
This converts the arguments originally meant for `wpmu_create_blog()` to the ones used by `wp_insert_site()`.

Follow-up to [47011].

Fixes #47195.
Built from https://develop.svn.wordpress.org/trunk@47013


git-svn-id: http://core.svn.wordpress.org/trunk@46813 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-25 21:41:02 +00:00
Sergey Biryukov
cf54349cb7 Tests: Replace most instances of wpmu_delete_blog() not specifically testing that function with wp_delete_site().
Follow-up to [47011].

See #47195.
Built from https://develop.svn.wordpress.org/trunk@47012


git-svn-id: http://core.svn.wordpress.org/trunk@46812 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-25 18:17:01 +00:00
Sergey Biryukov
e2231ec703 Tests: Switch WP_UnitTest_Factory_For_Blog::create_object() to use wp_insert_site().
Map some arguments for backward compatibility with `wpmu_create_blog()` previously used there.

Props davidbaumwald, danielbachhuber, jeremyfelt, SergeyBiryukov.
See #47195.
Built from https://develop.svn.wordpress.org/trunk@47011


git-svn-id: http://core.svn.wordpress.org/trunk@46811 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-25 18:12:02 +00:00
Sergey Biryukov
8990cf9296 Media: Make sure attachment_url_to_postid() performs a case-sensitive search for the uploaded file name.
Previously, the first available match was returned, regardless of the case, which was not always the expected result.

Props archon810, ben.greeley, tristangemus, vsamoletov, SergeyBiryukov.
Fixes #39768.
Built from https://develop.svn.wordpress.org/trunk@47010


git-svn-id: http://core.svn.wordpress.org/trunk@46810 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-25 02:26:03 +00:00
Sergey Biryukov
8073fd3ec0 Docs: Use a third-person singular verb for comment template function descriptions, per the documentation standards.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@47009


git-svn-id: http://core.svn.wordpress.org/trunk@46809 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-24 16:19:01 +00:00
Sergey Biryukov
9c68816a21 Docs: Improve documentation for get_comment_author_url().
Props stevenlinx.
Fixes #49076.
Built from https://develop.svn.wordpress.org/trunk@47008


git-svn-id: http://core.svn.wordpress.org/trunk@46808 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-24 16:10:05 +00:00
Sergey Biryukov
bb70f4e530 Docs: Correct the note about the CORE_UPGRADE_SKIP_NEW_BUNDLED constant in $_new_bundled_files global description.
In order to tell WordPress not to install new bundled themes on update, `CORE_UPGRADE_SKIP_NEW_BUNDLED` should be set to `true`, as the name suggests, not `false`.

Follow-up to [39064].

Props tomgreer, knutsp, crdunst.
See #49056.
Built from https://develop.svn.wordpress.org/trunk@47007


git-svn-id: http://core.svn.wordpress.org/trunk@46807 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-23 18:00:02 +00:00
Sergey Biryukov
246a035d99 Docs: Improve documentation for admin menu functions:
* `get_admin_page_parent()`
* `get_admin_page_title()`
* `get_plugin_page_hook()`
* `get_plugin_page_hookname()`
* `user_can_access_admin_page()`

Add missing descriptions and `@since` tags.

Props subrataemfluence, kennithnichol, stevenlinx, SergeyBiryukov.
Fixes #44253, #49067.
Built from https://develop.svn.wordpress.org/trunk@47006


git-svn-id: http://core.svn.wordpress.org/trunk@46806 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-23 14:36:04 +00:00
Sergey Biryukov
f501814eac Upgrade/Install: When creating the .htaccess file in insert_with_markers(), make sure it has 0644 as a minimum set of permissions.
Props rcutmore, dd32, i3anaan.
Fixes #40572.
Built from https://develop.svn.wordpress.org/trunk@47005


git-svn-id: http://core.svn.wordpress.org/trunk@46805 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-22 02:45:03 +00:00
Sergey Biryukov
9b3a895631 Shortcodes: Introduce apply_shortcodes() as an alias for do_shortcode().
This better aligns with the semantics of applying filters to the input and returning a result, rather than performing an action and outputting to the current buffer.

Props ljasinskipl, thefarlilacfield.
Fixes #37422.
Built from https://develop.svn.wordpress.org/trunk@47004


git-svn-id: http://core.svn.wordpress.org/trunk@46804 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-21 20:12:03 +00:00
Sergey Biryukov
5e8fe89ef5 Shortcodes: Make sure wp.shortcode.string() accepts the attrs array keys in any order.
Props yale01, georgestephanis, adamsilverstein, zsusag, mircoraffinetti, SergeyBiryukov.
Fixes #36263.
Built from https://develop.svn.wordpress.org/trunk@47003


git-svn-id: http://core.svn.wordpress.org/trunk@46803 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-21 18:34:04 +00:00
Sergey Biryukov
27d9bac051 Administration: Add doing_wp_cron to wp_removable_query_args().
It's a single-use URL parameter that does not need to be passed to canonical URLs in the admin.

Props dlh.
Fixes #49017.
Built from https://develop.svn.wordpress.org/trunk@47002


git-svn-id: http://core.svn.wordpress.org/trunk@46802 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-21 16:14:04 +00:00
Sergey Biryukov
7b70f584a7 Tests: Don't fail the test in WP_UnitTestCase_Base::skipOnAutomatedBranches() if Travis environment variables are unavailable, it prevents from running the test locally.
Follow-up to [47000].

See #49050.
Built from https://develop.svn.wordpress.org/trunk@47001


git-svn-id: http://core.svn.wordpress.org/trunk@46801 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-20 12:15:04 +00:00
Sergey Biryukov
01b91b2a0f Tests: Correct the check for pull requests in WP_UnitTestCase_Base::skipOnAutomatedBranches().
Mark the test as failed if the environment variables are unavailable.

Fixes #49050.
Built from https://develop.svn.wordpress.org/trunk@47000


git-svn-id: http://core.svn.wordpress.org/trunk@46800 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-20 01:12:01 +00:00
Sergey Biryukov
a5deda7083 Build/Test Tools: Pass the TRAVIS_BRANCH and TRAVIS_PULL_REQUEST environment variables along to the Docker container.
This ensures that `WP_UnitTestCase::skipOnAutomatedBranches()` has access to these variables.

See #49050, #47767.
Built from https://develop.svn.wordpress.org/trunk@46999


git-svn-id: http://core.svn.wordpress.org/trunk@46799 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-20 00:03:01 +00:00
Sergey Biryukov
d391a2633c Tests: Skip external HTTP test for recommended PHP and MySQL versions on 503 errors.
Fixes #49049.
Built from https://develop.svn.wordpress.org/trunk@46998


git-svn-id: http://core.svn.wordpress.org/trunk@46798 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-19 20:29:01 +00:00
whyisjake
464615e876 Editor: Add unit tests for v5.3.1 block serialization functions
r46896 was intended to have included unit tests for the block serialization functions added as part of the changeset.

Props: @aduth.
Fixes: #49048 


Built from https://develop.svn.wordpress.org/trunk@46997


git-svn-id: http://core.svn.wordpress.org/trunk@46797 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-19 18:50:01 +00:00
Sergey Biryukov
5d5bf01d12 Tests: In test_readme(), if the HTTP request to secure.php.net or dev.mysql.com failed, include response code in the error message.
See #40533, #44613.
Built from https://develop.svn.wordpress.org/trunk@46996


git-svn-id: http://core.svn.wordpress.org/trunk@46796 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-19 15:45:05 +00:00
Sergey Biryukov
c677634788 Tests: Remove unused cache keys from data_get_site_caches().
Follow-up to [46990].

See #40363.
Built from https://develop.svn.wordpress.org/trunk@46991


git-svn-id: http://core.svn.wordpress.org/trunk@46791 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 03:22:02 +00:00
Sergey Biryukov
5f6a36ceb6 Networks and Sites: Remove invalidation of unused cache keys in clean_blog_cache().
Props spacedmonkey, flixos90, thamaraiselvam.
Fixes #40363.
Built from https://develop.svn.wordpress.org/trunk@46990


git-svn-id: http://core.svn.wordpress.org/trunk@46790 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 02:59:02 +00:00
Sergey Biryukov
4edec193bc Users: When creating the first user on installation, populate the Website profile field with the site URL.
Skip setting the field if the user already exists, which is the case when the user tables are being shared among multiple sites.

Props EFAREM, eclare, darrenlambert, zachflauaus, viralsampat.
Fixes #35778.
Built from https://develop.svn.wordpress.org/trunk@46989


git-svn-id: http://core.svn.wordpress.org/trunk@46789 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 02:26:03 +00:00
Sergey Biryukov
694913d65f I18N: Make the minimum input length to start searching posts in the "Insert/edit link" modal localizable.
Props Toro_Unit, birgire, miyauchi, swissspidy, ocean90.
Fixes #44662.
Built from https://develop.svn.wordpress.org/trunk@46988


git-svn-id: http://core.svn.wordpress.org/trunk@46788 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 01:15:03 +00:00
Sergey Biryukov
6e7080036f Docs: Improve comments in tests/formatting/redirect.php per the documentation standards.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@46987


git-svn-id: http://core.svn.wordpress.org/trunk@46787 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 00:28:01 +00:00
Sergey Biryukov
8c709ed78c Docs: Add @method notation for WP_UnitTest_Factory_For_Term::create_and_get() for consistency with other factories.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@46986


git-svn-id: http://core.svn.wordpress.org/trunk@46786 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 00:26:02 +00:00
Sergey Biryukov
396647666f Docs: Various documentation fixes for unit test factories.
See #48303.
Built from https://develop.svn.wordpress.org/trunk@46985


git-svn-id: http://core.svn.wordpress.org/trunk@46785 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-18 00:19:02 +00:00
Sergey Biryukov
2cf3fb14ee Tests: Use delta comparison in test_should_fall_back_to_last_post_modified() to avoid race conditions.
See #48957.
Built from https://develop.svn.wordpress.org/trunk@46981


git-svn-id: http://core.svn.wordpress.org/trunk@46781 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-17 21:33:02 +00:00
Andrew Ozz
6403619f92 Upload: Run the final file name collision test in wp_unique_filename() for each existing file + 1.
Props pbiron.
See #48975.

Built from https://develop.svn.wordpress.org/trunk@46976


git-svn-id: http://core.svn.wordpress.org/trunk@46776 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-17 20:52:03 +00:00
Sergey Biryukov
da041582df Date/Time: Ensure that get_feed_build_date() correctly handles a modified post object with invalid date.
* Clarify in the documentation that the function returns `false` on failure.
* Consistently pass the return value through the `get_feed_build_date` filter.

Props Rarst, dd32, azaozz, tellyworth.
Fixes #48957.
Built from https://develop.svn.wordpress.org/trunk@46974


git-svn-id: http://core.svn.wordpress.org/trunk@46774 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-17 20:43:03 +00:00
Sergey Biryukov
8eb278d19a Docs: Clarify that get_lastpostdate() and get_lastpostmodified() can return false on failure.
The both use `_get_last_post_time()` internally.

Props Rarst.
See #48957.
Built from https://develop.svn.wordpress.org/trunk@46973


git-svn-id: http://core.svn.wordpress.org/trunk@46773 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-17 20:26:01 +00:00
Sergey Biryukov
bbd898b1dd Upgrade/Install: Remove unused global in upgrade_430_fix_comments().
Props adnan.limdi.
Fixes #41970.
Built from https://develop.svn.wordpress.org/trunk@46972


git-svn-id: http://core.svn.wordpress.org/trunk@46772 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-17 16:45:03 +00:00
Sergey Biryukov
d273235abd Login/Registration: Pass the error data to the wp_login_failed action.
Props hamedmoodi, rixeo.
Fixes #49007.
Built from https://develop.svn.wordpress.org/trunk@46971


git-svn-id: http://core.svn.wordpress.org/trunk@46771 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-17 15:36:01 +00:00
Sergey Biryukov
a79636f82a Docs: Correct @type for timeout argument in WP_Http::request().
Props georgestephanis, benedictsinger.
Fixes #49005.
Built from https://develop.svn.wordpress.org/trunk@46970


git-svn-id: http://core.svn.wordpress.org/trunk@46770 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-17 15:25:01 +00:00