From: <ap...@vh...> - 2005-11-14 14:39:41
|
Author: apevec Date: 2005-11-14 15:38:27 +0100 (Mon, 14 Nov 2005) New Revision: 994 Modified: trunk/ccm-ldn-theme/src/com/arsdigita/london/theme/ui/ThemeForm.java Log: fail with full stack trace when theme directory cannot be created Modified: trunk/ccm-ldn-theme/src/com/arsdigita/london/theme/ui/ThemeForm.java =================================================================== --- trunk/ccm-ldn-theme/src/com/arsdigita/london/theme/ui/ThemeForm.java 2005-11-14 14:35:30 UTC (rev 993) +++ trunk/ccm-ldn-theme/src/com/arsdigita/london/theme/ui/ThemeForm.java 2005-11-14 14:38:27 UTC (rev 994) @@ -355,7 +355,9 @@ ThemeApplication.getConfig().getDefaultThemeManifest()); } - newDirectory.mkdirs(); + if ( !newDirectory.mkdirs() ) { + throw new UncheckedWrapperException("Cannot create theme directory "+newDirectory.getAbsolutePath()); + } ManifestReader reader = new FileWriterManifestReader(is, newDirectory); @@ -406,7 +408,7 @@ } catch (IOException e) { throw new UncheckedWrapperException( "Error reading from " + filePath + - " or writing to " + m_newDirectory.getAbsolutePath()); + " or writing to " + m_newDirectory.getAbsolutePath(), e); } } } |