Page Menu
Home
DevCentral
Search
Configure Global Search
Log In
Files
F333267
Configure automatic updates for Wordpress
No One
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Authored By
dereckson
Feb 6 2017, 12:07
2017-02-06 12:07:52 (UTC+0)
Size
1 KB
Referenced Files
None
Subscribers
None
Configure automatic updates for Wordpress
View Options
<?php
/**
* Plugin Name: Extra settings for dereckson.be
* Description: Adds extra settings to this WordPress installation
* Version: 0.1
* Author: Dereckson
* Author URI: https://www.dereckson.be/
* License: PD
*/
add_filter
(
'automatic_updates_send_debug_email'
,
'__return_false'
);
add_filter
(
'auto_core_update_send_email'
,
'auto_core_update_send_email_callback'
);
add_filter
(
'automatic_updates_is_vcs_checkout'
,
'__return_false'
,
1
);
/**
* Determines when to send en e-mail fore core update (only on failure)
*
* @param bool $send Whether to send the email. Default true.
* @param string $type The type of email to send.
* Can be one of 'success', 'fail', 'critical'.
* @param object $core_update The update offer that was attempted.
* @param mixed $result The result for the core update. Can be WP_Error.
*
* @return bool true if a mail should be sent; otherwise, false.
*/
function
auto_core_update_send_email_callback
(
$send
,
$type
,
$core_update
,
$result
)
{
return
$send
&&
(
$type
!==
'success'
);
}
File Metadata
Details
Attached
Mime Type
text/plain; charset=utf-8
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
79889
Default Alt Text
Configure automatic updates for Wordpress (1 KB)
Attached To
Mode
P251 Configure automatic updates for Wordpress
Attached
Detach File
Event Timeline
Log In to Comment