* Informs the user that some of the elements in their Telegram Passport contain errors; for bots only. The user will not be able to resend the elements, until the errors are fixed.
13
*/
14
class SetPassportElementErrors extends TdFunction
15
{
16
public const TYPE_NAME = 'setPassportElementErrors';
17
18
/**
19
* User identifier.
20
*/
21
protected int $userId;
22
23
/**
24
* The errors.
25
*
26
* @var InputPassportElementError[]
27
*/
28
protected array $errors;
29
30
public function __construct(int $userId, array $errors)
31
{
32
$this->userId = $userId;
33
$this->errors = $errors;
34
}
35
36
public static function fromArray(array $array): SetPassportElementErrors