Commit Graph

21604 Commits

Author SHA1 Message Date
Boone Gorges
5c3a51e827 Tests: Add tests demonstrating wp_set_object_terms() behavior when matching $terms.
See #37009.
Built from https://develop.svn.wordpress.org/trunk@37647


git-svn-id: http://core.svn.wordpress.org/trunk@37613 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 21:35:27 +00:00
Rachel Baker
99cca27041 REST API: Create the general wp_check_jsonp_callback() function for validating JSONP callback functions.
Move the REST API JSONP callback validation check into a separate function named `wp_check_jsonp_callback()`. This allows plugins to use the built-in validation when handling JSONP callbacks.
Extremely Important Note: If you send JSONP in your custom response, make sure you prefix the response with `/**/`. This will mitigate the Rosetta Flash exploit. You should also send the `X-Content-Type-Options:nosniff` header, or even better, use the REST API infrastructure.

Props rmccue.
Fixes #28523.
Built from https://develop.svn.wordpress.org/trunk@37646


git-svn-id: http://core.svn.wordpress.org/trunk@37612 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 21:34:28 +00:00
Dominik Schilling
00056f8d71 Template: Pass $blog_id to the get_custom_logo filter.
Props achbed, juanfra.
Fixes #36639.
Built from https://develop.svn.wordpress.org/trunk@37645


git-svn-id: http://core.svn.wordpress.org/trunk@37611 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 21:24:27 +00:00
Boone Gorges
e453dc610a Tests: Move wp_set_object_terms() tests to their own file.
This is a redo of [37642], this time not done in the not right place.

See #37009.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37610 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 21:23:28 +00:00
Boone Gorges
bd5e7aef62 Add test demonstrating that wp_insert_term() will suffix a slug if the new term's auto-generated slug matches that of an existing term.
See #37009.
Built from https://develop.svn.wordpress.org/trunk@37641


git-svn-id: http://core.svn.wordpress.org/trunk@37609 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 21:04:28 +00:00
Drew Jaynes
5415629ad2 Nav Menus: Move the Walker_Nav_Menu class to its own file.
The new class-walker-nav-menu.php file is loaded in nav-menu-template.php for backward compatibility purposes.

Fixes #37035. See #33413.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37608 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 15:18:31 +00:00
Drew Jaynes
2c7f5217cd Docs: Relocate some @see tags and add missing @access tags to method and property DocBlocks in Walker_Nav_Menu.
See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37607 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 05:47:27 +00:00
Drew Jaynes
16b51fb44d Docs: Reformat several parameter descriptions in Walker_Nav_Menu to directly reference wp_nav_menu() rather than use inline @see tags.
See #32246.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37606 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 05:45:28 +00:00
Ryan McCue
fe7a3ab5d9 Autoload: Add missed @since tags to SPL shim.
See #36926.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37605 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 03:59:28 +00:00
Ryan McCue
0def38c30b Autoload: Introduce shim for SPL autoloading.
For PHP 5.2, SPL can be disabled. As SPL provides the support for multiple autoloaders, this needs to be shimmed if not available.

Fixes #36926.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37604 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-06 03:24:29 +00:00
Dominik Schilling
d8357b76c5 Upgrader: Don't use Language_Pack_Upgrader_Skin::before() and Language_Pack_Upgrader_Skin::after() when translations are up to date.
Avoids a PHP notice since `Language_Pack_Upgrader_Skin::before()` tries to access a non-existent update.
Also, change the `up_to_date` string to use the plural form because translations are only updated in bulk mode.

Fixes #36615.
Built from https://develop.svn.wordpress.org/trunk@37635


git-svn-id: http://core.svn.wordpress.org/trunk@37603 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-05 12:22:30 +00:00
Boone Gorges
57e5e7fd79 Taxonomy: No, really, don't pass results of 'count' query through 'get_terms' filter.
[37623] used the wrong parameter name (count=true instead of fields=count).

For greater flexibility and forward compatibility with other potential changes
to the return value of `get_terms()`, we now do a looser check: any non-array
value is excluded from the filter.

Fixes #36992.
Built from https://develop.svn.wordpress.org/trunk@37634


git-svn-id: http://core.svn.wordpress.org/trunk@37602 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-04 12:20:28 +00:00
Jeremy Felt
52c0a8fdd8 Multisite: Add initial tests for WP_MS_Sites_List_Table
Different tests are used for subdomain and subdirectory installs as domain and path are searched differently for each. Only trailing wildcard searches are tested because leading wildcards are not yet supported.

See #36675.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37601 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-03 14:38:27 +00:00
Gary Pendergast
44c1f82df3 Editor: 'undefined' !== 'undefiend'
Fix a typo in [37630].

See #36662.


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


git-svn-id: http://core.svn.wordpress.org/trunk@37600 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-03 04:54:27 +00:00
Boone Gorges
71a94a3871 Add tests for remove_query_arg().
Props borgesbruno.
Fixes #37008.
Built from https://develop.svn.wordpress.org/trunk@37631


git-svn-id: http://core.svn.wordpress.org/trunk@37599 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-03 04:31:30 +00:00
Andrew Ozz
5e5aa1a69a Editor: do not use the modal-open class to determine when the wpLink modal is open. This is a class used in Bootstrap and may be present when wpLink is not open. Store the open/closed state instead.
Fixes #36662.
Built from https://develop.svn.wordpress.org/trunk@37630


git-svn-id: http://core.svn.wordpress.org/trunk@37598 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 23:58:28 +00:00
Jeremy Felt
2211c28a37 Multisite: Remove superfluous code from network_edit_site_nav()
* Remove output buffering.
* Remove `esc_attr()` when outputting hard coded class names.
* Update documentation.

Fixes #15800.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37597 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 22:29:27 +00:00
Jeremy Felt
460f4740a2 Multisite: Replace $wpdb->blog queries in get_site_by_path() with get_sites()
Props spacedmonkey, DrewAPicture.
See #35791.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37596 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 21:46:29 +00:00
Andrew Ozz
26b1d5f927 Auto-embedding:
- We already match URLs on their own line, add another regex to match URLs in their own paragraphs.
- Always exclude the `\s<>"` characters when matching.
- Add more unit tests.

Props iseulde, azaozz.
Fixes #25387.
Built from https://develop.svn.wordpress.org/trunk@37627


git-svn-id: http://core.svn.wordpress.org/trunk@37595 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 21:24:30 +00:00
Aaron Jorbin
cedaaaf779 Introduce filters for skipping parts of the bootstrap process
Non web interfaces with WordPress (such as wp-cli) need to be able to bypass certain checks in the bootstrap process. This introduces three new filters to allow for those checks to be skipped.

1. Provides a way of forcefully bypassing wp_maintenance().
2. Provides a way of forcefully bypassing wp_debug_mode(). See https://github.com/wp-cli/wp-cli/issues/177
3. Provide a way of forcefully skipping loading wp-content/advance-cache.php. See https://github.com/wp-cli/wp-cli/pull/164

These filters should not be used by plugins (in fact, they run before plugins are loaded, so they can't be used by plugins). In general, they should only be used in non-web interactions with WordPress.

See #34936.
Props jorbin, DrewAPicture.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37594 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 18:47:27 +00:00
Boone Gorges
e202610ac8 Comments: Improve caching for hierarchical queries.
Hierarchical comment queries work by first fetching the IDs of top-level
comments, and then filling the descendant tree one level at a time based on the
top-level results. When top-level comment IDs are found in the cache,
`WP_Comment_Query` does not generate the SQL used to fetch these comments. In
this case, the `fill_descendants()` query does not have enough information
to fill children. As a result, descendant comments were failing to be filled
in cases where the top-level comments were found in the cache.

This was a minor bug previously, because comment caches were not maintained
between pageloads. Since comment caches are now persistent [37613], the problem
becomes evident anywhere that a persistent object cache is in use.

The solution is to cache parent-child relationships, so that when top-level
comments are found in the cache, descendant comments should be found there as
well.

Fixes #36487.
Built from https://develop.svn.wordpress.org/trunk@37625


git-svn-id: http://core.svn.wordpress.org/trunk@37593 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 18:28:27 +00:00
Rachel Baker
d287f19a0f Comments: Remove debugging code left in WP_Comments_List_Table->get_views().
Originally introduced in [9556] and leftover from [15578].

Props dabnpits.
Fixes #36938.
Built from https://develop.svn.wordpress.org/trunk@37624


git-svn-id: http://core.svn.wordpress.org/trunk@37592 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 15:07:28 +00:00
Boone Gorges
f6980a5fd7 Taxonomy: Don't pass results of 'count' query through 'get_terms' filter.
Use of the 'get_terms' filter was consolidated in [37572], with the
introduction of `WP_Term_Query`. At that time, the result of 'count=true'
queries began being filtered by 'get_terms'. This breaks existing 'get_terms'
callbacks, which often assume that the returned value will be an array or a
`WP_Error` object.

Props JustinSainton.
Fixes #36992.
Built from https://develop.svn.wordpress.org/trunk@37623


git-svn-id: http://core.svn.wordpress.org/trunk@37591 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 14:38:29 +00:00
Boone Gorges
0d4aa4df6c Remove unused variable from get_terms().
Missed in [37572]. See #35381.

Props JustinSainton.
See #36992.
Built from https://develop.svn.wordpress.org/trunk@37622


git-svn-id: http://core.svn.wordpress.org/trunk@37590 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 14:29:29 +00:00
Andrew Ozz
c59504f760 Editor wpLink: swap the order of innerText and textContent to avoid getting styled text in IE.
Props dougwollison.
Fixes #36783.
Built from https://develop.svn.wordpress.org/trunk@37621


git-svn-id: http://core.svn.wordpress.org/trunk@37589 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 03:09:28 +00:00
Jeremy Felt
fc1db9b413 Multisite: Replace $wpdb->blog queries in ms-functions.php with get_sites()
`get_sites()` is now used in:
* `domain_exists()`
* `wp_update_network_site_counts()`
* `get_blog_id_from_url()`

Props spacedmonkey, jeremyfelt.
See #35791.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37588 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 02:26:29 +00:00
Andrew Ozz
82ee5ca020 Editor: ensure the page is refreshed when the users navigate to it with the Back or Forward buttons. In these cases the browsers usually load the page from (memory) cache and it contains the old editor content.
Fixes #35852.
Built from https://develop.svn.wordpress.org/trunk@37619


git-svn-id: http://core.svn.wordpress.org/trunk@37587 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 01:30:27 +00:00
Jeremy Felt
a6de56b473 Multisite: Bump last_changed cache on site update and creation
When a site is added, updated, or deleted, the `site_ids` cache for a query will no longer be reliable. Bumping `last_changed` will force a new query for site IDs.

See #35791.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37586 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-02 00:59:27 +00:00
Jeremy Felt
53b27a9b0b Multisite: Replace wp_get_sites() internals with get_sites()
`get_sites()` should be considered a replacement for `wp_get_sites()`. Backward compatibility is maintained in the meantime by using `get_site()` to populate the return data with associative arrays rather than `WP_Site` objects.

Props spacedmonkey, flixos90.
See #35791.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37585 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 23:39:28 +00:00
Jeremy Felt
8dd52fb458 Multisite: Introduce get_sites()
`get_sites()` is a wrapper for `WP_Site_Query`.

Props spacedmonkey, DrewAPicture.
See #35791.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37584 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 23:21:27 +00:00
Drew Jaynes
5e5f5dd4e9 Docs: Improve return descriptions for get_the_category() and get_the_term() to specifically notate that an array of WP_Term objects is returned on success.
See #32246. 

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


git-svn-id: http://core.svn.wordpress.org/trunk@37583 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 22:46:28 +00:00
Boone Gorges
c70e3246e2 Use clean_comment_cache() in wp_insert_comment().
Previously, only the 'last_changed' incrementor was manually invalidated, since
the newly created comment did not yet exist in the cache. However, this created
an inconsistency with the other comment CRUD functions, which result in the
'clean_comment_cache' action firing.

Props spacedmonkey.
See #36906.
Built from https://develop.svn.wordpress.org/trunk@37614


git-svn-id: http://core.svn.wordpress.org/trunk@37582 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 21:56:27 +00:00
Boone Gorges
1f2635d52b Make the 'comment' cache group persistent.
'comment' was made non-persistent in [7986], to address the difficulty of
reliable cache invalidation. Since then, the comment system has improved such
that we can be more confident that caches are being busted as needed.

Props spacedmonkey.
Fixes #36906.
Built from https://develop.svn.wordpress.org/trunk@37613


git-svn-id: http://core.svn.wordpress.org/trunk@37581 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 21:26:27 +00:00
Aaron Jorbin
59571c6961 Update grunt-patch-wordpress to 0.4.0
This update adds two main features for your WordPress development happiness.

1) GitHub URL support. You can now use `grunt patch:https://github.com/aaronjorbin/develop.wordpress/pull/3` with any copy of WordPress on GitHub. No longer will you need to download the patch manually.  Works for both core and develop mirrors on GitHub.  

2) Upload patches directly from the command line. No longer will you need to create a patch and manually upload it to trac. `grunt upload_patch:20000` will upload a patch to the appropriate ticket after a user enters a WordPress.org username and password. This is limited to users with the appropriate XML-RPC privileges in trac (right now, that is just bug gardeners). You still need to manually add the `has patch` keyword.  

Full changelog: https://github.com/aaronjorbin/grunt-patch-wordpress/compare/0.3.0...0.4.0

Fixes #35917.
Props netweb, ericlewis, michaelbeil, jorbin.

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


git-svn-id: http://core.svn.wordpress.org/trunk@37580 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 21:25:40 +00:00
Andrea Fercia
bf3b51adaf Accessibility: improve the color contrast in the Edit Comment "Status" box.
The current orange and red used for the radio button labels in the Edit Comment
"Status" box don't have a sufficient color contrast ratio with the background.
Removing the colors improves accessibility and consistency.

See #35659, #35622.
Fixes #36967.
Built from https://develop.svn.wordpress.org/trunk@37611


git-svn-id: http://core.svn.wordpress.org/trunk@37579 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 17:51:27 +00:00
Andrea Fercia
8bd79e49f0 Accessibility: match the visual and tab order in the Media Modal grid.
By moving the Details sidebar after the attachments grid, the tab order is
greatly improved for keyboard users and matches the logical and visual order.

Fixes #36909.
Built from https://develop.svn.wordpress.org/trunk@37610


git-svn-id: http://core.svn.wordpress.org/trunk@37578 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 17:39:27 +00:00
Boone Gorges
58882148b2 Add tests demonstrating individual comment cache invalidation.
See #36906.
Built from https://develop.svn.wordpress.org/trunk@37609


git-svn-id: http://core.svn.wordpress.org/trunk@37577 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 17:16:27 +00:00
Boone Gorges
8fd42ed20e Add tests demonstrating query cache invalidation on comment CRUD actions.
See #36909.
Built from https://develop.svn.wordpress.org/trunk@37608


git-svn-id: http://core.svn.wordpress.org/trunk@37576 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 17:00:29 +00:00
Rachel Baker
2485b63b00 Comments: Break the inline display of comment content urls on the Moderate Comment screen
Uses the CSS rule `word-break: break-all`.

Fixes #36568.
Built from https://develop.svn.wordpress.org/trunk@37607


git-svn-id: http://core.svn.wordpress.org/trunk@37575 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 16:05:30 +00:00
Ella Iseulde Van Dorpe
6b4662ab96 Editor: autoresize fixes for text
* Resize on backspace.
* Don't make it smaller than the minimum height.

Props azaozz, iseulde.

See #36482.


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


git-svn-id: http://core.svn.wordpress.org/trunk@37571 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 10:24:30 +00:00
Gary Pendergast
6d583100d1 Tests: Fix an incorrect @ticket header introduced in [37601].
See #32405, #36917.


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


git-svn-id: http://core.svn.wordpress.org/trunk@37570 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 02:41:27 +00:00
Gary Pendergast
69147eb345 Database: Split the logic of wpdb::init_charset() into a separate method.
The logic for determining the appropriate character set and collation to use is becoming more complex, particularly with the recent additions of [37522] and [37523]. As `init_charset()` has side effects, and makes use of constants instead of parameters, it's not possible to unit test this logic.

This commit splits the logic part of `init_charset()` out into a new method, `wpdb::determine_charset()`, along with appropriate unit tests.

See #32105, #37522.

Fixes #36917.


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


git-svn-id: http://core.svn.wordpress.org/trunk@37569 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-01 02:38:29 +00:00
Boone Gorges
8dbceabc60 Add tests for no_found_rows behavior of WP_Query.
See #29952.
Built from https://develop.svn.wordpress.org/trunk@37600


git-svn-id: http://core.svn.wordpress.org/trunk@37568 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-31 19:29:30 +00:00
Boone Gorges
477f6346eb Ensure that get_terms() can accept querystring-style arguments.
Prior to [37572], arguments passed to `get_terms()` were passed immediately
through `wp_parse_args()`, which made it possible to pass arguments as a
querystring (`hide_empty=0`) rather than an array
(`array( 'hide_empty' => false )`). [37572] moved default argument parsing
into `WP_Term_Query`, while assuming that arguments passed to `get_terms()`
would be formatted as an array.

To provide compatibility, we now parse all args passed to `get_terms()` into
an array before processing.

See #35381.
Built from https://develop.svn.wordpress.org/trunk@37599


git-svn-id: http://core.svn.wordpress.org/trunk@37567 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-31 12:54:29 +00:00
Dion Hulse
c959b63539 Updates: Only use the filename component of URLs to form part of the temporary filename.
Previously we were passing the entire URL to `wp_tempnam()` (incorrectly) which caused the query string to be used as part of the temporary filename.
We now only use the file component of a url such as `https://example.com/filename.zip?arg1=1&arg2=2....&arg100=100` to prevent a long filename.

Fixes #34938

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


git-svn-id: http://core.svn.wordpress.org/trunk@37566 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-31 02:21:29 +00:00
Andrew Ozz
ba7f3cffc1 TinyMCE: check if wp.mce.views exists before loading the wpview plugin. Fixes a js error when the rest of the media scripts are not loaded.
Fixes #36977.
Built from https://develop.svn.wordpress.org/trunk@37597


git-svn-id: http://core.svn.wordpress.org/trunk@37565 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-30 22:05:27 +00:00
Ella Iseulde Van Dorpe
5502219779 Editor: better resizing for text editor
* Use `scrollHeight` to resize the text editor.
* Don't scroll the cursor into view when under the text editor's toolbar, it
  involves cloning the content which is quite slow.

Props iseulde, azaozz.

See #36482.


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


git-svn-id: http://core.svn.wordpress.org/trunk@37564 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-30 20:32:30 +00:00
Boone Gorges
54700d4ea6 Tests: Change some 'group' annotations to 'ticket'.
Built from https://develop.svn.wordpress.org/trunk@37595


git-svn-id: http://core.svn.wordpress.org/trunk@37563 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-30 04:38:28 +00:00
Boone Gorges
fc1d2c99c9 In WP_Meta_Query, don't cast meta_value to CHAR.
`CHAR` is redundant, since the `meta_value` column is `LONGTEXT`. Meanwhile,
use of `CAST()` causes MySQL to ignore any index that the administrator may
have added to the column.

A number of automated tests were doing searches for `CAST` in the SQL strings
generated by `WP_Meta_Query` (for reasons unrelated to the `CAST()` behavior).
These tests have been updated to expect the new query format.

Props ericlewis.
Fixes #36625.
Built from https://develop.svn.wordpress.org/trunk@37594


git-svn-id: http://core.svn.wordpress.org/trunk@37562 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-30 04:36:27 +00:00
Boone Gorges
e64aa77090 Don't clear object relationship caches on term update.
Since [37573], object relationship caches (`{$taxonomy}_relationships`)
contain term IDs rather than term objects. See #36814. As such, it's no longer
necessary to clear these caches when a term is updated; none of the data that's
changed on update (name, description, count, etc) is stored in the relationship
cache.

Fixes #36251.
Built from https://develop.svn.wordpress.org/trunk@37593


git-svn-id: http://core.svn.wordpress.org/trunk@37561 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-30 04:11:27 +00:00