Skip to content

Commit a8febcf

Browse files
committed
Filter and remove empty results
Signed-off-by: Riddhesh Sanghvi <[email protected]>
1 parent fe0ffdc commit a8febcf

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

php/class-ee-docker.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -273,6 +273,6 @@ public static function create_volumes( $prefix, $volumes, $update_to_docker_pref
273273
public static function get_volumes_by_label( $label ) {
274274
$launch = EE::launch( sprintf( 'docker volume ls --filter="label=org.label-schema.vendor=EasyEngine" --filter="label=io.easyengine.site=%s" -q', $label ) );
275275

276-
return explode( PHP_EOL, trim( $launch->stdout ) );
276+
return array_filter( explode( PHP_EOL, trim( $launch->stdout ) ), 'trim' );
277277
}
278278
}

0 commit comments

Comments
 (0)