Skip to:
Content

BuddyPress.org

Changeset 8406


Ignore:
Timestamp:
05/10/2014 01:13:18 AM (12 years ago)
Author:
boonebgorges
Message:

Avoid PHP notices during unit tests

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tests/phpunit/testcases/core/avatars.php

    r8395 r8406  
    3131
    3232    private function rrmdir( $dir ) {
    33         foreach ( glob( $dir . '/*' ) as $file ) {
     33        $d = glob( $dir . '/*' );
     34
     35        if ( empty( $d ) ) {
     36            return;
     37        }
     38
     39        foreach ( $d as $file ) {
    3440            if ( is_dir( $file ) ) {
    3541                $this->rrmdir( $file );
Note: See TracChangeset for help on using the changeset viewer.