Could you please clarify the requirement 2.15 of the Technical Guidelines "Method chaining in class design MUST be avoided"?
We have like real holy war here b/c of this rule.
It seems to me that according to CQRS principle that only means we must not use "return $this" while designing new classes.
And that does not mean we can't use constructions like $this->storeManager->getStore()->getId() in our code.
Is that correct?
Or ->getStore()->getId() is also prohibited by this rule? And so we must first get store into some variable. And then get Id using the variable.
Thank you in advance.
Could you please clarify the requirement 2.15 of the Technical Guidelines "Method chaining in class design MUST be avoided"?
We have like real holy war here b/c of this rule.
It seems to me that according to CQRS principle that only means we must not use "return $this" while designing new classes.
And that does not mean we can't use constructions like
$this->storeManager->getStore()->getId()in our code.Is that correct?
Or
->getStore()->getId()is also prohibited by this rule? And so we must first get store into some variable. And then get Id using the variable.Thank you in advance.