It seems like you call parent on a different method (getCart() instead of getDuplicatedCart()). Are you sure this is correct? If so, you might want to change this to $this->getCart().
This check looks for a call to a parent method whose name is different than
the method from which it is called.
This check looks for a call to a parent method whose name is different than the method from which it is called.
Consider the following code:
The
getFirstName()
method in theSon
calls the wrong method in the parent class.