Skip to content

Commit 57a3174

Browse files
committed
ES syntax update for newer version
1 parent 893aa9b commit 57a3174

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

lib/MetaCPAN/ES.pm

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,14 +68,12 @@ sub search ( $self, %args ) {
6868

6969
my $index = $args{index} // $self->{index};
7070
my $type = $args{type} // $self->{type};
71-
my @fields = ( $args{fields} ? ( fields => $args{fields} ) : () );
7271
my @size = ( $args{size} ? ( size => $args{size} ) : () );
7372

7473
return $self->{es}->search(
7574
index => $index,
7675
type => $type,
7776
body => $body,
78-
@fields,
7977
@size,
8078
);
8179
}
@@ -95,11 +93,9 @@ sub scroll ( $self, %args ) {
9593
return $self->{es}->scroll_helper(
9694
index => $self->{index},
9795
type => $self->{type},
98-
size => ( $args{size} // 500 ),
9996
body => ( $args{body} // { query => { match_all => {} } } ),
10097
search_type => 'scan',
10198
scroll => ( $args{scroll} // '30m' ),
102-
( $args{fields} ? ( fields => $args{fields} ) : () ),
10399
);
104100
}
105101

0 commit comments

Comments
 (0)