Skip to content

SeriesInfoExtractorServiceImpl.extractReleaseYear() shouldn't return year in future #787

Open
@php-coder

Description

@php-coder

At present, our regexp matches years till 2099:

// Related to RELEASE_YEAR_REGEXP and used in unit tests.
protected static final int MAX_SUPPORTED_RELEASE_YEAR = 2099;
// Regular expression matches release year of the stamps (from 1840 till 2099).
private static final Pattern RELEASE_YEAR_REGEXP =
Pattern.compile("18[4-9][0-9]|19[0-9]{2}|20[0-9]{2}");

We shouldn't return year if it's in future.

Metadata

Metadata

Assignees

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions