site-kit-wp icon indicating copy to clipboard operation
site-kit-wp copied to clipboard

Remove infrastructure related to storage and synchronization of user input settings between service and plugin

Open kuasha420 opened this issue 3 years ago • 1 comments

Feature Description

Once #5898 is implemented and the User Input answers are being stored and read from the Site's database, any leftover code related to storage and synchronization of user input settings between Site Kit service and plugin should be removed.


Do not alter or remove anything below. The following sections will be managed by moderators only.

Acceptance criteria

  • Code related to the storage, retrieval, and synchronization of user input answers on the Site Kit service should be removed.

Implementation Brief

  • In includes/Core/Util/User_Input_Settings.php, remove the following:
    • Remove the TRANSIENT_NAME constant.
    • Remove the transients and user_transients properties and update the User_Input_Settings::__construct method to remove the transient and user_transient arguments.
    • Remove is_connected_to_proxy, sync_with_proxy, are_settings_empty, cache_settings, get_settings and set_settings methods.
  • Note: Deleting the User_Input_State class and its references will be implemented in #5900.

Test Coverage

  • Remove the existing test cases for the above-removed methods.

QA Brief

Changelog entry

kuasha420 avatar Sep 25 '22 21:09 kuasha420

  • The code related to storage and synchronization of user input answers should be removed from the code base.

@kuasha420 let's make this more specific to the SK service as described. This is a bit too loose as defined.

I made this change above as it's a rather simple one to not block this 👍

aaemnnosttv avatar Oct 12 '22 20:10 aaemnnosttv

IB ✅

tofumatt avatar Oct 25 '22 00:10 tofumatt

The User_Input_Settings has been renamed to User_Input, and most of the infrastructure code related to storage has been removed as part of #5898. The remaining part is the are_settings_empty method, its usage, and test cases. IMO, it should be wise to remove it as part of #5900 and close this issue because some of the uses of the are_settings_empty method will be removed in 5900.

cc: @kuasha420 @nfmohit @jimmymadon

hussain-t avatar Dec 20 '22 09:12 hussain-t