From dde95f531891115af6092fe03e06ec2f6cb7bb9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20G=C3=BCnther?= Date: Fri, 31 Aug 2018 11:42:12 +0200 Subject: [PATCH] Don't raise always when pandoc is missing from PATH [ci skip] --- .../text_formatting/formats/markdown/pandoc_downloader.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/open_project/text_formatting/formats/markdown/pandoc_downloader.rb b/lib/open_project/text_formatting/formats/markdown/pandoc_downloader.rb index 19c6555de8..cc56a9ef21 100644 --- a/lib/open_project/text_formatting/formats/markdown/pandoc_downloader.rb +++ b/lib/open_project/text_formatting/formats/markdown/pandoc_downloader.rb @@ -76,6 +76,12 @@ module OpenProject::TextFormatting::Formats end status.success? && stdout.match(/^pandoc [23]\./i) + rescue StandardError => e + if raise_msg.present? + raise raise_msg + end + + false end def forced_pandoc_path