Detecting code, doesn't work

I want to achieve that when I enter a code in my UI, the code does a function for me. The issues is that it doesn’t return anything, and instead returns false.

This is the code.

local codeVar = Instance.new("NumberValue")

Remotes.Passcode.OnClientEvent:Connect(function(code)
	codeVar.Value = code
end)

PasscodeUI.TextButton.MouseButton1Click:Connect(function()
	if PasscodeUI.TextBox.Text == codeVar.Value  then 
		print("True")

	else 
		return false
	end
end)

Fixed my own code by adding tostring. Forgot about that.