SettingsHub not using GetService

Filing this under bug reports because it triggers an error in games that rename services.

14:24:51.681 - Players is not a valid member of DataModel
14:24:51.682 - Stack Begin
14:24:51.682 - Script 'CoreGui.RobloxGui.Modules.Settings.SettingsHub', Line 544
14:24:51.682 - Stack End

The code in question being:

spawn(function()
	local playerPermissionsModule = require(RobloxGui.Modules.PlayerPermissionsModule)
	local localPlayer = game.Players.LocalPlayer
	while not localPlayer do
		game.Players.PlayerAdded:wait()
		localPlayer = game.Players.LocalPlayer
	end
	this.OverridesPlayerScriptsLabel.Text = "PlayerScripts: " ..getOverridesPlayerScripts()
	this.OverridesPlayerScriptsLabel.TextScaled = not this.OverridesPlayerScriptsLabel.TextFits
	this.OverridesPlayerScriptsLabel.Visible = isTestEnvironment or playerPermissionsModule.IsPlayerAdminAsync(localPlayer)
end)

I’m unsure what the implications of this are.

6 Likes

Hi! We are catching up on some historical bugs and I was not able to reproduce this issue. If this issue still exists, could you please file a new bug report with additional info? Thank you!