This commit is contained in:
Anthony Stirling
2024-05-26 15:31:34 +01:00
parent 2066bb2ae8
commit 5dee64ab7b
7 changed files with 27 additions and 25 deletions

View File

@@ -56,7 +56,7 @@ public class ConvertImgPDFController {
String filename =
Filenames.toSimpleFileName(file.getOriginalFilename())
.replaceFirst("[.][^.]+$", "");
result =
PdfUtils.convertFromPdf(
pdfBytes,
@@ -65,10 +65,9 @@ public class ConvertImgPDFController {
singleImage,
Integer.valueOf(dpi),
filename);
if(result == null || result.length == 0) {
logger.error("resultant bytes for {} is null, error converting ", filename);
if (result == null || result.length == 0) {
logger.error("resultant bytes for {} is null, error converting ", filename);
}
if (singleImage) {
String docName = filename + "." + imageFormat;

View File

@@ -67,7 +67,7 @@ public class BlankPageController {
String pageText = textStripper.getText(document);
boolean hasText = !pageText.trim().isEmpty();
Boolean blank = false;
Boolean blank = true;
if (hasText) {
logger.info("page " + pageIndex + " has text, not blank");
blank = false;