function oasl_steamid ($user_data, $identity)
{
$steamid = array_reduce ($identity->accounts, function ($id, $acc) {
return (stripos ($acc->domain, 'steam') !== false and !empty ($acc->userid)) ? $acc->userid : NULL;
});
if (isset ($steamid)) {
update_user_meta ($user_data->ID, 'steamid', $steamid);
}
}
add_action ('oa_social_login_action_after_user_insert', 'oasl_steamid', 10, 2);
Please sign in to your OneAll account to ask a new question or to contribute to the discussions.
Please click on the link below to connect to the forum with your OneAll account.