php – How to Change Default Core Slug in WordPress – BBpress Plugin

I’m making custom plugin..

And I want to sync userswp plugin and bbpress plugin, so I do not want to use bbpress account page and use userswp account page instead.

But userswp plugin and bbpress plugin url is different.

if not using userswp, and you want to look at users page the url like this:

But userswp is different, the url like this:

I know that, we can filter hook using bbp_get_user_profile_url(), but when in this page:

and author_url below time, direct to user url that make the topic.

Actually, I can just change it in bbpress/includes/core/options.php

But, I just curious is there any way to change default slug in bbpress without changing core in options.php?

For example like this:

 * Return the single user slug
 * @since 2.1.0 bbPress (r3759)
 * @param string $default Optional. Default value 'users'
 * @return string
function bbp_get_user_slug( $default = 'users' ) {

    // Filter & return
    return apply_filters( 'bbp_get_user_slug', bbp_maybe_get_root_slug() . get_option( '_bbp_user_slug', $default ) );

change $default = ‘users’ into $default = ‘profile’ in code snippet or custom plugins.

I hope my question is understandable, Thank you!