瀏覽代碼

Removing unnecessary private method

Jhonny Mertz 8 年之前
父節點
當前提交
c018ecd9c6
共有 1 個文件被更改,包括 1 次插入6 次删除
  1. 1 6
      src/main/java/com/github/jhonnymertz/wkhtmltopdf/wrapper/Pdf.java

+ 1 - 6
src/main/java/com/github/jhonnymertz/wkhtmltopdf/wrapper/Pdf.java

@@ -80,13 +80,8 @@ public class Pdf {
     }
 
     public File saveAs(String path) throws IOException, InterruptedException {
-        return saveAs(path, getPDF());
-    }
-
-    private File saveAs(String path, byte[] document) throws IOException {
         File file = new File(path);
-        FileUtils.writeByteArrayToFile(file, document);
-
+        FileUtils.writeByteArrayToFile(file, getPDF());
         return file;
     }