-
Notifications
You must be signed in to change notification settings - Fork 131
Closed
Labels
[Plugin] Regenerate Existing ImagesIssues for the Regenerate Existing Images moduleIssues for the Regenerate Existing Images module
Description
Create a new perflab_create_background_job()
function that creates a new job. The job will be a new term within the background_job
taxonomy.
Acceptance Criteria
- Create a new
perflab_create_background_job()
function - Function accepts the following parameters
$job_name
- A string the defines the job action to be run. This is required.$job_data
- An array of additional data to pass to the job action. This is optional and defaults to an empty array.
- The function will process the parameters and create a new
background_job
term as follows.- The
$job_name
is used as the term name. - The
$job_data
will be assigned to the term as term meta with the keyjob_data
.
- The
- The function will return the following depending on success or failure.
- On failure, the function returns the
WP_Error
fromwp_insert_term
. - On success, the function returns the newly created Term ID.
- On failure, the function returns the
felixarntz
Metadata
Metadata
Assignees
Labels
[Plugin] Regenerate Existing ImagesIssues for the Regenerate Existing Images moduleIssues for the Regenerate Existing Images module