How do I get the character from ReplicatedStorage module

Hi,

I feel kind of dumb for asking this question but how do I get the player’s character without the waitforchild yielding the entire module for eternity? here’s what I mean:

local Knit = require(game:GetService("ReplicatedStorage").Packages.Knit)

local ClassController = Knit.CreateController{
	Name = "ClassController"
}

local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Players = game:GetService("Players")

local Animations: Folder = ReplicatedStorage.Assets.Animations
local Tools: Folder = ReplicatedStorage.Assets.ClassTools
local AbilityClasses: Folder = ReplicatedStorage.Sources.Classes.Ability
local Player = Players.LocalPlayer

function ClassController:SelectClass(Class: string)
	if not AbilityClasses[Class] then
		warn(Class, "was not found.")
		return
	end

	if not Animations[Class] then
		warn(Class, "animations were not found.")
		return
	end

	if not AbilityClasses[Class] then
		warn(Class, "module was not found.")
		return
	end

	if not Tools[Class] then
		warn(Class, "tool was not found.")
		return
	end
	
	print("H")

	local Character = Player.CharacterAdded:Wait() or Player.Character
	local Humanoid = Character:WaitForChild("Humanoid")
	
	print("I")

	local ClassTool = Tools[Class]
	local ClassAnimations = Animations[Class]
	local ClassModule = require(AbilityClasses[Class]).new(ClassAnimations,ClassTool, Character)
	
	Humanoid:SetAttribute("Class", Class)
	
	ClassModule:Init()
end

function ClassController:Reset(Class: string)

end

ClassController:SelectClass("Reaper") -- test

return ClassController

for me, looking at this module looks completely fine until you check the output…
The output shows H being printed out and never the “I”. I think this is because local Character = Player.CharacterAdded:Wait() or Player.Character is yielding the entire script. I even put this in the beginning of the script and literally nothing ran after the line.

change:

local Character = Player.CharacterAdded:Wait() or Player.Character

to:

local Character = Player.Character or Player.CharacterAdded:Wait()

because it means if the character doesnt exist, then we wait until a character does exist. instead of, wait until a character is added and then check if a character exists

Wow, I feel dumb. I think i’ve faced this problem countless of times just to have the solution this simple. Thank you.