MissingProjectParameterException.class.php 551 B

123456789101112131415161718192021222324
  1. <?php
  2. /**
  3. * Custom exception when project is not specified
  4. *
  5. * @author Christopher Han <xiphux@gmail.com>
  6. * @copyright Copyright (c) 2012 Christopher Han
  7. * @package GitPHP
  8. * @subpackage Exception
  9. */
  10. class GitPHP_MissingProjectParameterException extends GitPHP_MessageException
  11. {
  12. /**
  13. * Constructor
  14. *
  15. * @param string $message message
  16. * @param int $code code
  17. */
  18. public function __construct($message = '', $code = 0)
  19. {
  20. if (empty($message))
  21. $message = 'Project is required';
  22. parent::__construct($message, true, 200, $code);
  23. }
  24. }