-
-
Notifications
You must be signed in to change notification settings - Fork 221
Closed
Description
Version: 2.7.5
Bug Description
In case of PHP 7.4 entity with required scalar properties Tracy do not show required properties without value.
For example imagine simple object OrderInfoAddress:
<?php
declare(strict_types=1);
namespa
6E25
ce Baraja\Cart;
final class OrderInfoAddress
{
private string $street;
private string $city;
private string $zip;
private string $companyName = '';
private string $ic = '';
private bool $buyAsCompany = false;
private bool $invoiceAddressIsDifferent = false;
}In case of simple dump like:
bdump(new OrderInfoAddress)Tracy show initialized properties with value only:
Steps To Reproduce
Use my test object.
Expected Behavior & Possible Solution
Tracy should show all properties, but instead, value shows information property is uninitialized.
This settings can be detected by \ReflectionProperty by simple logic: $property->isInitialized($instance).
Current behavior is confusing. In the case of inheritance of multiple classes, it is not possible to unambiguously determine whether the property was inherited or just has no value.
Thanks!
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
