Repository navigation
Conversation
| public boolean isHotspotSupported() { | ||
| return mIsTetheringSupportedConfig && mIsTetheringSupported && mHasTetherableWifiRegexs | ||
| && UserManager.get(mContext).isUserAdmin(mUserTracker.getUserId()); | ||
| && !UserManager.get(mContext).hasUserRestrictionForUser( |
There was a problem hiding this comment.
is this definitely enough? The settings themselves also gate:
if (!WifiUtils.isWifiMultiuserEnabled()) {
setIfOnlyAvailableForAdmins(true);
} public static boolean isWifiMultiuserEnabled() {
return com.android.settings.connectivity.Flags.wifiMultiuser()
|| com.android.settings.flags.Flags.enableWifiMultiuser();
}There was a problem hiding this comment.
Looking into it (GrapheneOS/platform_packages_apps_Settings@d8a9fc8), AFAICT this flag was only relevant during the system settings UI rollout for the recently added multi-user wifi support, as the wifi settings UI was gated for admin-only before it, the flag is set at build time to true in all current grapheneos build target configs and I don't see a scenario where it would be false except maybe upstream changes/rollbacks.
I can definitely add the check here if preferred though, your call.
There was a problem hiding this comment.
Oh I have no idea, I was just looking into fixing this myself yesterday. Probably you're right the flags are obsolete.
663fda1 to
ef40213
Compare
Hotspot is now available for secondary users so this check needs to be updated to allow the quick settings tile for them
Fixes GrapheneOS/os-issue-tracker#8123