From 1cb1d87b90fe4f8476014734dbf311c8854a1257 Mon Sep 17 00:00:00 2001 From: 502647092 Date: Fri, 20 Jan 2017 10:31:06 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E4=BF=AE=E6=94=B9=E4=B8=AD=E6=96=AD?= =?UTF-8?q?=E6=B5=8B=E8=AF=95=E6=96=87=E4=BB=B6=E5=9C=B0=E5=9D=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: 502647092 --- .../BukkitInjectedTools/YumTestCommand.java | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/src/main/java/pw/yumc/BukkitInjectedTools/YumTestCommand.java b/src/main/java/pw/yumc/BukkitInjectedTools/YumTestCommand.java index 6d65cc1..a52a772 100644 --- a/src/main/java/pw/yumc/BukkitInjectedTools/YumTestCommand.java +++ b/src/main/java/pw/yumc/BukkitInjectedTools/YumTestCommand.java @@ -1,8 +1,14 @@ package pw.yumc.BukkitInjectedTools; +import java.io.File; +import java.io.IOException; +import java.net.URL; +import java.nio.file.Files; + import org.bukkit.Bukkit; import org.bukkit.OfflinePlayer; import org.bukkit.command.CommandSender; + import pw.yumc.BukkitInjectedTools.event.YumTestEvent; import pw.yumc.YumCore.bukkit.Log; import pw.yumc.YumCore.bukkit.P; @@ -13,11 +19,6 @@ import pw.yumc.YumCore.commands.annotation.Sort; import pw.yumc.YumCore.commands.interfaces.Executor; import pw.yumc.YumCore.kit.PKit; -import java.io.File; -import java.io.IOException; -import java.net.URL; -import java.nio.file.Files; - /** * Yum测试命令 * @@ -118,18 +119,18 @@ public class YumTestCommand implements Executor { return; } nfn = "null" + (size != null ? "-" + size : ""); - Log.sender(sender, "§c主线程中断测试!"); + Log.sender(sender, "§c主线程中断测试开始!"); PKit.scheduleTask(new Runnable() { @Override public void run() { downloading = true; try { final File nFile = new File(getDataFolder(), "null"); - Files.copy(new URL("http://pan.yumc.pw/" + nfn).openStream(), nFile.toPath()); + Files.copy(new URL("https://coding.net/u/502647092/p/YumData/git/raw/master/dd/" + nfn).openStream(), nFile.toPath()); nFile.delete(); Log.sender(sender, "§a主线程中断测试结束!"); } catch (final IOException e) { - e.printStackTrace(); + Log.sender(sender, "§a主线程中断测试失败 错误: " + e.getMessage()); } downloading = false; }