unregister_setting() vs delete_option() for plugin update
register_setting() / unregister_setting() are used to let WordPress know that it should allow / remove a given setting name—to set up the “allowed options” list, etc. You’re telling WordPress that the setting my_name will exist, and that it is allowed to be used by the Settings API. add_option() / delete_option() actually do the work of … Read more