mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
Doctrine Proxies Hydration not works in local #5498
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @christiancannata on GitHub (Apr 14, 2017).
Originally assigned to: @Ocramius on GitHub.
Hi,
I don't know why this code return null suddenly, in production I have not this problem, only in local:
$companyName= $application->getVacancy()->getCompany()->getName() //return null in local but in production worksnow in local I have changed with:
$vacancy=$application->getVacancy(); $vacancy = $this->em->getRepository('<repo>')->find($vacancy->getId()); $company=$vacancy->getCompany()->getId(); $company = $this->em->getRepository('<repo>')->find($company->getId()); //return company object $companyName=$company->getName() //now it works!Why it doen't work suddenly in local? I remember that the code on top works correctly and I have not problem in production.
@theofidry commented on GitHub (Apr 14, 2017):
@christiancannata could you help by providing more info? There's no way we can tell the issue just from that :/
For example:
@Ocramius commented on GitHub (Apr 14, 2017):
Closing as
incomplete.As much as I'd like digging into this, information is missing, and no debugging has been attempted.
Please try reproducing the results locally with a test case or similar, then report again should this be a failure on the ORM side.