mirror of
https://github.com/revanced/smali.git
synced 2025-05-29 04:10:13 +02:00
Use a switch statement in mapDexVersionToApi
This commit is contained in:
parent
a237739444
commit
2f29256bdf
@ -35,19 +35,18 @@ public class VersionMap {
|
||||
public static final int NO_VERSION = -1;
|
||||
|
||||
public static int mapDexVersionToApi(int dexVersion) {
|
||||
if (dexVersion == 35) {
|
||||
return 23;
|
||||
switch (dexVersion) {
|
||||
case 35:
|
||||
return 23;
|
||||
case 37:
|
||||
return 25;
|
||||
case 38:
|
||||
return 27;
|
||||
case 39:
|
||||
return 28;
|
||||
default:
|
||||
return NO_VERSION;
|
||||
}
|
||||
if (dexVersion == 37) {
|
||||
return 25;
|
||||
}
|
||||
if (dexVersion == 38) {
|
||||
return 27;
|
||||
}
|
||||
if (dexVersion == 39) {
|
||||
return 28;
|
||||
}
|
||||
return NO_VERSION;
|
||||
}
|
||||
|
||||
public static int mapApiToDexVersion(int api) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user