Problem with Datastore

I am creating a new game and I have made a Datastore to save various value relating to character customization. I have a folder in serverstorage which is cloned onto the player when they join the game. The script gives no errors and prints everything that it should. However, when rejoining the game the value is nil. Any help would be appreciated.

local DatastoreService = game:GetService("DataStoreService")
local DataStore = DatastoreService:GetDataStore("CharacterCustomization1")

local loaded = {}

game.Players.PlayerAdded:Connect(function(player)
	local success, value = pcall(DataStore.GetAsync, DataStore, player.UserId)
	if success == false then player:Kick("DataStore failed to load") return end
	if value == nil then print("No Data") end
	local data = value or {}
	print(player.UserId,"Loaded:", data)
	for i, folder in game.ServerStorage.PlayerData:GetChildren() do
		local subData = data[folder.Name] or {}
		local clone = folder:Clone()
		for i, child in clone:GetChildren() do
			child.Value = subData[child.Name] or child.Value
		end
		clone.Parent = player
	end
	loaded[player] = true
end)

game.Players.PlayerRemoving:Connect(function(player)
	if loaded[player] == nil then return end
	local data = {}
	for i, folder in game.ServerStorage.PlayerData:GetChildren() do
		local subData = {}
		for i, child in player[folder.Name]:GetChildren() do
			subData[child.Name] = child.Value
		end
		data[folder.Name] = subData
		folder:Destroy()
	end
	local success, value = pcall(DataStore.SetAsync, DataStore, player.UserId, data)
	print(player.UserId,"Saved:", data)
	loaded[player] = nil
end)

game:BindToClose(function()
	while next(loaded) ~= nil do
		task.wait()
	end
end)

I believe this is an error, I think this may be passing DataStore as the first argument and not as the ‘self’ argument:

local success, value = pcall(DataStore.GetAsync, DataStore, player.UserId)

Try it without pcall like this:

local value = DataStore:GetAsync(tostring(player.UserId))

I’m not sure if the tostring is required but its what I use just to be sure.

Sorry for taking so long to respod, I took a bit of a break from this project and decided to come back to it. I wanted to let you know that this did not change anything, Is there another line of code I need to edit?