Skip to content
This repository has been archived by the owner on Feb 7, 2024. It is now read-only.

Don't check Libreoffice error string #1055

Merged
merged 1 commit into from
Dec 4, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions etp-backend/src/main/clj/solita/etp/service/laskutus.clj
Original file line number Diff line number Diff line change
Expand Up @@ -297,15 +297,15 @@
(xlsx/set-sheet-landscape sheet true)
(xlsx/fill-sheet! xlsx sheet tasmaytysraportti [5000 5000 7000 5000 5000])
(xlsx/save-xlsx xlsx xlsx-path)))
(let [{:keys [exit err] :as sh-result} (libreoffice/run-with-args
(let [{:keys [exit] :as sh-result} (libreoffice/run-with-args
"--convert-to"
"pdf"
(.getName xlsx-file)
:dir
(.getParent xlsx-file))
pdf-exists? (.exists pdf-file)]
(io/delete-file xlsx-path)
(if (and (zero? exit) (str/blank? err) pdf-exists?)
(if (and (zero? exit) pdf-exists?)
pdf-file
(throw (ex-info "Creating tasmaytysraportti PDF failed."
(assoc sh-result
Expand Down