AppException.php 541 B

123456789101112131415161718192021222324
  1. <?php
  2. /**
  3. * [Discuz!] (C)2001-2099 Comsenz Inc.
  4. * This is NOT a freeware, use is subject to license terms
  5. *
  6. * $Id: AppException.php 28702 2012-03-08 06:43:58Z yexinhao $
  7. */
  8. if(!defined('IN_DISCUZ')) {
  9. exit('Access Denied');
  10. }
  11. class Cloud_Service_AppException extends Exception {
  12. public function __construct($message, $code = 0) {
  13. if ($message instanceof Exception) {
  14. parent::__construct($message->getMessage(), intval($message->getCode()));
  15. } else {
  16. parent::__construct($message, intval($code));
  17. }
  18. }
  19. }