Action - Admin Defaults

This fired on the admin panel being loaded. It can be used to ensure that any necessary settings or theme options are added or instantiated in the database.

Example:

// Declare plugin option name
define( 'FEED_URLS_OPTION', 'RSS Feed URLs' );
// Ensure plugin option exists in the DB
add_action( 'admin_set_defaults', function() {
$option_exists = does_row_exist( 'theme_options', 'name', FEED_URLS_OPTION );
if( !$option_exists ) {
add_theme_option( FEED_URLS_OPTION, '' );
}
});