View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0007179 | OXID eShop (all versions) | 4. ------ eShop Core ------- | public | 2020-10-05 10:56 | 2024-07-24 10:41 |
Reporter | s.diez | Assigned To | |||
Priority | normal | Severity | minor | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 6.2.2 | ||||
Fixed in Version | 6.4.0 | ||||
Summary | 0007179: Private Functions in Core/Email | ||||
Description | In Core/Email several functions are declared as private, which are needed by modules. Email::getRenderer This function is needed for every mail you want to send to render the mail body with Smarty/Twig. Even if this is only a help function which can be copied, I don't see any reason for private ones. Email::shouldProductReviewLinksBeIncluded Also only a help function but the reason for private is not clear to me. Input from customer: In Core/Email sind verschiedene Funktionen als private deklariert, die von Modulen benötigt werden. Email::getRenderer Diese Funktion wird quasi bei jeder Mail die man verschicken will benötigt, um den Mailbody mit Smarty/Twig rendern zu können. Auch wenn dies nur eine Hilfsfunktion ist, die nachgebaut werden kann, sehe ich keinen Grund für private. Email::shouldProductReviewLinksBeIncluded Auch nur eine Hilfsfunktion aber der Grund für private ist mir hier auch nicht klar. | ||||
Additional Information | - es - | ||||
Tags | No tags attached. | ||||
Theme | Not defined | ||||
Browser | Not defined | ||||
PHP Version | Not defined | ||||
Database Version | Not defined | ||||
|
This was changed with https://github.com/OXID-eSales/oxideshop_ce/commit/d99866a5e0c7d84a5541d2f22b71af02879f9384 in oxideshop_ce v6.10.0 used in OXID >=6.4.0 for getRenderer to be protected instead of private. For shouldProductReviewLinksBeIncluded this is still private. In this case the usecase is not really clear to me. This is a very basic method that only check for 2 settings: 1. Are reviews activated anyway and 2. Is the setting includeProductReviewLinksInEmail true ... which is basically what this simple getter is all about. So: Either you just use this and put some additional check on top (e.g. to activate/deactivate it in special cases) or just change the setting. In the end we strive to make as much of the code public, but I don't see any urgent need right now. Please open a separate ticket for this if you think different, but please explain your usecase, so we can properly rank this. |