small changes

This commit is contained in:
Ziver Koc 2020-11-10 21:53:51 +01:00
parent 4d513b407a
commit 2276a55722

View file

@ -103,11 +103,13 @@ public class Templator {
public Templator(File tmpl) throws IOException { public Templator(File tmpl) throws IOException {
if(tmpl == null) if(tmpl == null)
throw new IOException("File can not be null!"); throw new IOException("File can not be null!");
this.data = new HashMap<>(); this.data = new HashMap<>();
this.file = tmpl; this.file = tmpl;
parseTemplate(FileUtil.getContent(file)); parseTemplate(FileUtil.getContent(file));
this.lastModified = file.lastModified(); this.lastModified = file.lastModified();
} }
public Templator(String tmpl){ public Templator(String tmpl){
this.data = new HashMap<>(); this.data = new HashMap<>();
parseTemplate(tmpl); parseTemplate(tmpl);