Making WordPress.org


Ignore:
Timestamp:
02/27/2015 01:54:28 AM (10 years ago)
Author:
obenland
Message:

WP.org Themes: Only the filename is interesting here, not the whole path.

See #745.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sites/trunk/wordpress.org/public_html/wp-content/plugins/theme-directory/class-wporg-themes-upload.php

    r1338 r1342  
    305305        $screenshots = preg_grep( '/screenshot.(jpg|jpeg|png|gif)/', $theme_files );
    306306        usort( $screenshots, array( $this, 'sort_by_string_length' ) );
    307 
    308         $this->theme->screenshot = array_pop( $screenshots );
     307        $screenshot = array_pop( $screenshots );
     308
     309        $this->theme->screenshot = basename( $screenshot );
    309310
    310311        return (bool) $this->theme->screenshot;
Note: See TracChangeset for help on using the changeset viewer.