aboutsummaryrefslogtreecommitdiffstats
path: root/lib/helper.php
diff options
context:
space:
mode:
authorBart Visscher <bartv@thisnet.nl>2013-07-21 22:29:50 +0200
committerBart Visscher <bartv@thisnet.nl>2013-07-21 22:29:50 +0200
commitdf8ad46daef960accd1e307f74e7bcb705e9fc7b (patch)
tree7848816e8d4aa6074c4d78bdf45cd5f5074e798b /lib/helper.php
parent37a731bcad4636f682a2cbcc59dabc9e60494b01 (diff)
downloadnextcloud-server-df8ad46daef960accd1e307f74e7bcb705e9fc7b.tar.gz
nextcloud-server-df8ad46daef960accd1e307f74e7bcb705e9fc7b.zip
Change exit calls to throwing an exception
This way the error won't be fatal in a unit test
Diffstat (limited to 'lib/helper.php')
-rw-r--r--lib/helper.php3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/helper.php b/lib/helper.php
index df0d120976d..ca508e1d933 100644
--- a/lib/helper.php
+++ b/lib/helper.php
@@ -176,8 +176,7 @@ class OC_Helper {
}elseif( file_exists( OC::$SERVERROOT."/core/img/$image" )) {
return OC::$WEBROOT."/core/img/$image";
}else{
- echo('image not found: image:'.$image.' webroot:'.OC::$WEBROOT.' serverroot:'.OC::$SERVERROOT);
- die();
+ throw new RuntimeException('image not found: image:'.$image.' webroot:'.OC::$WEBROOT.' serverroot:'.OC::$SERVERROOT);
}
}