Making WordPress.org


Ignore:
Timestamp:
03/29/2017 02:48:32 PM (9 years ago)
Author:
dd32
Message:

Plugin Directory: Clear the caches used by the plugins info endpoint in addition to the update check caches.
Ensure the plugin info cache key won't hit the memcache key size limits by md5'ing plugin slugs >200char.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/plugin-directory/standalone/class-plugins-info-api.php

    r4572 r5194  
    101101         */
    102102        protected function plugin_information_cache_key( $request ) {
    103                 return 'plugin_information:' . $request->slug . ':' . ( $request->locale ?: 'en_US' );
     103                return 'plugin_information:'
     104                        . ( strlen( $request->slug ) > 200 ? 'md5:' . md5( $request->slug ) : $request->slug )
     105                        . ':' . ( $request->locale ?: 'en_US' );
    104106        }
    105107
Note: See TracChangeset for help on using the changeset viewer.