Automattic / Automattic/jetpack

IDC: Factor functionality out of main Jetpack class

Open
#5,455 1 comment 0 reactions 0 assignees View on GitHub
[Pri] Low Enhancement IDC Task
Dominant language
PHP
Stars
1.8k
Forks
898
Avg merge
1d 18h
Merged PRs (30d)
774

Description

We've added a decent chunk of code to the main `Jetpack` class. For our own sanity, as well as for future developers of Jetpack, let's factor that code into a separate class.

We can factor methods like `sync_error_idc_validation()` and `check_identity_crisis()` out of the `Jetpack` class and into a new class like `Jetpack_IDC`.

This should make discovery of the code a bit easier, since we've got better naming and encapsulation, and should make it a bit easier to test.

Contributor guide

Open the contributing guide

Research direction

Locate the main `Jetpack` class and inspect `sync_error_idc_validation()` and `check_identity_crisis()`. Factor the IDC functionality into a new `Jetpack_IDC` class with clearer naming and encapsulation, then verify that the functionality remains available through the existing Jetpack behavior and is easier to test.

Written by the indexing model from the issue text.

Assessment

Tech stack
php, wordpress
Domain
backend
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.