diff --git a/src/net/sourceforge/plantuml/style/CommandStyleImport.java b/src/net/sourceforge/plantuml/style/CommandStyleImport.java index fe2f68f51..bdc6d5ab7 100644 --- a/src/net/sourceforge/plantuml/style/CommandStyleImport.java +++ b/src/net/sourceforge/plantuml/style/CommandStyleImport.java @@ -86,7 +86,9 @@ public class CommandStyleImport extends SingleLineCommand2 { if (path.startsWith("http://") || path.startsWith("https://")) { SURL url = SURL.create(path); try (InputStream remoteInputStream = url.openStream()) { - lines = BlocLines.load(remoteInputStream, location); + if (remoteInputStream != null) { + lines = BlocLines.load(remoteInputStream, location); + } } } else { final SFile styleFile = FileSystem.getInstance().getFile(path);