Making WordPress.org


Ignore:
Timestamp:
03/02/2023 01:24:44 PM (3 years ago)
Author:
akirk
Message:

Translate: fix a caching issue in the discussion

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/gp-translation-helpers/helpers/helper-translation-discussion.php

    r12435 r12443  
    441441            // Something was found in the cache.
    442442
    443             if ( self::is_temporary_post_id( $post_id ) && $create ) {
     443            if ( self::is_temporary_post_id( $post_id ) ) {
    444444                // a fake post_id was stored in the cache but we need to create an entry.
    445445                // Let's pretend a cache fail, so that we get a chance to create an entry unless one already exists.
     
    485485        }
    486486
    487         wp_cache_add( $cache_key, $post_id );
     487        wp_cache_set( $cache_key, $post_id );
    488488        return $post_id;
    489489    }
Note: See TracChangeset for help on using the changeset viewer.