Description
Currently the 'Magento\Catalog\Model\Product\Attribute\Frontend\Image' model is inheriting from the abstract class 'Magento\Eav\Model\Entity\Attribute\Frontend\AbstractFrontend'.
The class should inherit from 'Magento\Eav\Model\Entity\Attribute\Frontend\DefaultFrontend' instead (which inherits from the abstract). This would be more consistent with other frontend attributes (like datetime) and more flexible in extending the functionalities of the frontend attributes.
Preconditions
- PHP7.0
- MG2.1.2, MG2.1.3, MG2.1.4
Steps to reproduce
- Look at file Magento\Catalog\Model\Product\Attribute\Frontend\Image
Expected result
- class should inherit from Magento\Eav\Model\Entity\Attribute\Frontend\DefaultFrontend
Actual result
- class inherits from Magento\Eav\Model\Entity\Attribute\Frontend\AbstractFrontend
This fix would allow more flexibility when adding functionalities on the frontend attributes. You would not have to provide an extra preference to fix the 'incorrect' parent class for the image attributes.
An example of where this is already done in the core:
Magento\Eav\Model\Entity\Attribute\Frontend\Datetime