Made message signing in Cryptography use SHA512 as the message content for... #1

Closed
netkas wants to merge 421 commits from master into dev
Showing only changes of commit 26c7cd650f - Show all commits

View file

@ -41,7 +41,11 @@
$this->emailAddress = $data['email_address'] ?? null;
$this->phoneNumber = $data['phone_number'] ?? null;
if(is_int($data['birthday']))
if(!isset($data['birthday']))
{
$this->birthday = null;
}
elseif(is_int($data['birthday']))
{
$this->birthday = (new DateTime())->setTimestamp($data['birthday']);
}
@ -55,7 +59,7 @@
}
else
{
$this->birthday = null;
throw new \InvalidArgumentException("The birthday field must be a valid timestamp or date string.");
}
if($data['flags'])
@ -69,7 +73,11 @@
$this->enabled = $data['enabled'];
if(is_int($data['created']))
if(!isset($data['created']))
{
$this->created = new DateTime();
}
elseif(is_int($data['created']))
{
$this->created = (new DateTime())->setTimestamp($data['created']);
}