Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
WP Plugins
Cron-Control
Commits
1e354a2c
Commit
1e354a2c
authored
Feb 17, 2017
by
Erick Hitter
Browse files
Remove remaining references to CPT that aren't about legacy data cleanup
parent
40589036
Changes
3
Hide whitespace changes
Inline
Side-by-side
includes/class-events-store.php
View file @
1e354a2c
...
...
@@ -100,7 +100,7 @@ class Events_Store extends Singleton {
*/
/**
* Override cron option requests with data from
CPT
* Override cron option requests with data from
custom table
*/
public
function
get_option
()
{
// Use cached value for reads, except when we're unscheduling and state is important
...
...
@@ -215,7 +215,7 @@ class Events_Store extends Singleton {
}
/**
* Save cron events in
CPT
* Save cron events in
custom table
*/
private
function
convert_option
(
$new_value
)
{
if
(
is_array
(
$new_value
)
&&
!
empty
(
$new_value
)
)
{
...
...
includes/wp-cli/class-events.php
View file @
1e354a2c
...
...
@@ -320,7 +320,7 @@ class Events extends \WP_CLI_Command {
\
WP_CLI
::
line
(
__
(
'Locating event...'
,
'automattic-cron-control'
)
.
"
\n
"
);
// Look up full object
and confirm that the entry belongs to this plugin's CPT
// Look up full
event
object
$event
=
\
Automattic\WP\Cron_Control\get_event_by_attributes
(
array
(
'ID'
=>
$jid
,
)
);
if
(
is_object
(
$event
)
)
{
...
...
tests/test-events-store.php
View file @
1e354a2c
<?php
/**
* Class
Cron_Options_CPT
_Tests
* Class
Events_Store
_Tests
*
* @package Automattic_Cron_Control
*/
...
...
@@ -43,7 +43,7 @@ class Events_Store_Tests extends \WP_UnitTestCase {
}
/**
* Check that an event is stored properly in
a CPT entry
* Check that an event is stored properly in
table
*/
function
test_events_exist
()
{
global
$wpdb
;
...
...
@@ -63,7 +63,7 @@ class Events_Store_Tests extends \WP_UnitTestCase {
}
/**
* Check format of filtered array returned from
CPT
* Check format of filtered array returned from
table
*/
function
test_filter_cron_option_get
()
{
$event
=
Utils
::
create_test_event
();
...
...
@@ -115,7 +115,7 @@ class Events_Store_Tests extends \WP_UnitTestCase {
}
/**
* Test that events are unscheduled correctly by checking the
CPT
* Test that events are unscheduled correctly by checking the
table
*/
function
test_event_unscheduling_against_event_store
()
{
// Schedule two events and prepare their data a bit for further testing
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment