WordPress.org

Make WordPress Core


Ignore:
Timestamp:
08/29/2017 04:09:57 AM (3 years ago)
Author:
westonruter
Message:

Customize: Prevent potential cache corruption when finding a secondary changeset post by UUID.

Props dlh.
Fixes #41738.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/tests/customize/manager.php

    r41293 r41321  
    304304        $this->assertNull( $wp_customize->find_changeset_post_id( wp_generate_uuid4() ) );
    305305        $this->assertEquals( $post_id, $wp_customize->find_changeset_post_id( $uuid ) );
     306
     307        // Verify that the found post ID was cached under the given UUID, not the manager's UUID.
     308        $this->assertNotEquals( $post_id, $wp_customize->find_changeset_post_id( $wp_customize->changeset_uuid() ) );
    306309    }
    307310
Note: See TracChangeset for help on using the changeset viewer.