Net Library & util.AddNetworkString() throwing attempt to call field 'AddNetworkString' (a nil value)

I have not been able to find anyone else with a solution to this, according to all the documentation I’ve been able to find it looks correct. I setup a basic script to show you my issue.

This throws the error

[lua]if client then
local str = “”
net.Recieve(“tester”, function()
str = net.ReadString()
print(integer)
end)
else
local cheese = “cheese”;
util.AddNetworkString(“tester”)
net.Start(“tester”)
net.WriteString(cheese)
net.Broadcast()
end[/lua]

Not sure why, it always seems to happen. Am I missing something or is this a bug?

client is not the same thing as CLIENT.

[lua]
if CLIENT then
local str = “”
net.Recieve(“tester”, function()
str = net.ReadString()
print(integer)
end)
else
local cheese = “cheese”;
util.AddNetworkString(“tester”)
net.Start(“tester”)
net.WriteString(cheese)
net.Broadcast()
end

[/lua]

Ahh, I see. Thank you very much sir!

Have a good one.