diff --git a/command/jar/VasDolly.jar b/command/jar/VasDolly.jar index e71f2ab..2afba10 100644 Binary files a/command/jar/VasDolly.jar and b/command/jar/VasDolly.jar differ diff --git a/command/src/main/java/com/tencent/vasdolly/command/Util.java b/command/src/main/java/com/tencent/vasdolly/command/Util.java index d0205d5..483eff0 100644 --- a/command/src/main/java/com/tencent/vasdolly/command/Util.java +++ b/command/src/main/java/com/tencent/vasdolly/command/Util.java @@ -73,7 +73,7 @@ public static String getSignMode(File apkFile) { */ public static String readChannel(File apkFile) { String channel = ChannelReader.getChannelByV2(apkFile); - if (channel == null) { + if (channel.isEmpty()) { channel = ChannelReader.getChannelByV1(apkFile); } return channel; @@ -185,7 +185,7 @@ private static void generateV1ChannelApk(File baseApk, List channelList, //判断基础包是否已经包含渠道信息 String testChannel = ChannelReader.getChannelByV1(baseApk); - if (testChannel != null) { + if (!testChannel.isEmpty()) { System.out.println("baseApk : " + baseApk.getAbsolutePath() + " has a channel : " + testChannel + ", only ignore"); return; } diff --git a/helper/src/main/java/com/tencent/vasdolly/helper/ChannelReaderUtil.java b/helper/src/main/java/com/tencent/vasdolly/helper/ChannelReaderUtil.java index 3216917..3e7846c 100644 --- a/helper/src/main/java/com/tencent/vasdolly/helper/ChannelReaderUtil.java +++ b/helper/src/main/java/com/tencent/vasdolly/helper/ChannelReaderUtil.java @@ -39,7 +39,7 @@ public class ChannelReaderUtil { public static String getChannel(Context context) { if (mChannelCache == null) { String channel = getChannelByV2(context); - if (channel == null) { + if (channel.isEmpty()) { channel = getChannelByV1(context); } mChannelCache = channel;