Files
pathfinder/app/main/exception/registrationexception.php
Mark Friedrich 07d5be71b2 - added custom/editable ship jump logs, #709
- fixed DB setup error: "`system`.`description` can´t have a default value", closed #701
- upgraded "lazyload" js lib `v1.9.5` → `v1.9.7`
- upgraded multiple 3rd party NPM dependencies for Gulp build
2018-10-27 00:45:53 +02:00

38 lines
698 B
PHP

<?php
/**
* Created by PhpStorm.
* User: Exodus
* Date: 15.08.2015
* Time: 21:21
*/
namespace Exception;
class RegistrationException extends PathfinderException{
protected $codes = [
2000 => 403
];
/**
* form field name that causes this exception
* @var string
*/
private $field;
public function __construct(string $message, string $field = ''){
parent::__construct($message, 2000);
$this->field = $field;
}
/**
* get error object
* @return \stdClass
*/
public function getError() : \stdClass {
$error = parent::getError();
$error->field = $this->field;
return $error;
}
}