Changes between Initial Version and Version 1 of Ticket #42134, comment 9
- Timestamp:
- 06/07/2019 12:20:45 PM (6 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #42134, comment 9
initial v1 1 1 Looking at the code I'm seeing some places that can be improved. As this is a stand-alone function better checking for unexpected situation will improve functionality. 2 2 3 - get_userdatacan return unexpected data, as the user ID doesn't have to be valid4 - $admin_notificationis being determined using a filter, which can return an empty value; an email should not be send if there is no message3 - `get_userdata` can return unexpected data, as the user ID doesn't have to be valid 4 - `$admin_notification` is being determined using a filter, which can return an empty value; an email should not be send if there is no message 5 5 6 6 Site tite: … … 9 9 10 10 Some other concern I noticed: 11 The admin_email will be default in this patch to: 'support@' . $_SERVER['SERVER_NAME']11 The admin_email will be default in this patch to: `'support@' . $_SERVER['SERVER_NAME']` 12 12 But support is not a default emailbox. Suggesting to use "postmaster" or even considering of returning a WP_Error and not sending an email at all.