Skip to content

Creating IndexOptions using expireAfter method sets wrong options #4851

Closed
@mozzer39

Description

@mozzer39

Hi!
I have noticed a bug in IndexOptions class. Using expireAfter(Duration duration) method should set expire field with given expiration time, but duration parameter is not used and unique option is set instead.

public static IndexOptions expireAfter(Duration duration) {
IndexOptions options = new IndexOptions();
options.unique = Unique.YES;
return options;
}

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions