File tree Expand file tree Collapse file tree 2 files changed +12
-9
lines changed
src/main/java/com/magento/idea/magento2uct/packages Expand file tree Collapse file tree 2 files changed +12
-9
lines changed Original file line number Diff line number Diff line change @@ -38,16 +38,16 @@ public enum IndexRegistry {
38
38
private final String key ;
39
39
private final Class <?> type ;
40
40
private final IndexProcessor processor ;
41
- private final String [] versions ;
41
+ private final List < String > versions ;
42
42
43
43
IndexRegistry (
44
44
final Class <?> type ,
45
45
final IndexProcessor processor ,
46
- final String ... versions
46
+ final List < String > versions
47
47
) {
48
48
this .type = type ;
49
49
this .processor = processor ;
50
- this .versions = Arrays . copyOf ( versions , versions . length ) ;
50
+ this .versions = versions ;
51
51
key = this .toString ();
52
52
}
53
53
@@ -84,7 +84,7 @@ public IndexProcessor getProcessor() {
84
84
* @return List[String]
85
85
*/
86
86
public List <String > getVersions () {
87
- return Arrays . asList ( versions ) ;
87
+ return versions ;
88
88
}
89
89
90
90
/**
Original file line number Diff line number Diff line change @@ -51,11 +51,14 @@ private SupportedVersion(final String version) {
51
51
return versions ;
52
52
}
53
53
54
- public static String [] getSupportedVersionStrings () {
55
- return getSupportedVersions ()
56
- .stream ()
57
- .map (SupportedVersion ::toString )
58
- .toArray (String []::new );
54
+ public static List <String > getSupportedVersionStrings () {
55
+ final List <String > versions = new ArrayList <>();
56
+
57
+ for (final SupportedVersion version : getSupportedVersions ()) {
58
+ versions .add (version .getVersion ());
59
+ }
60
+
61
+ return versions ;
59
62
}
60
63
61
64
public static @ Nullable SupportedVersion getVersion (final @ NotNull String versionCandidate ) {
You can’t perform that action at this time.
0 commit comments