private static function CreateKey($Data, $Company = 1) { $State = isset($Data["State"]) ? $Data["State"] : 1; $CustomRef = isset($Data["Key"]) ? $Data["Key"] : false; $Key = Key::Create($Company, $State, $CustomRef); if ($Key != -1) { return $Key; } return false; }