Need to figure this out

This keeps telling me Line 1 is attempting to index a nil value (global ‘config’) and I tried everything in my power to fix this but nothing seems to work.

I’ve tried bracketing off the rolelist with a comma and tells me to check and make sure config is set properly.

Config = {
	Guild_ID = '1175544738523402250', -- Set to the ID of your guild (or your Primary guild if using Multiguild)
	Multiguild = false, -- Set to true if you want to use multiple guilds
	Guilds = {
		["HorizonNetwork"] = "main", -- Replace this with a name, like "main"
	},
	Bot_Token = 'MTE4MjU0MTQ5Mzk5MTM4NzI2Nw.G1iucP.vk8d8M4-gfykn6OfL3zlY0w-jGOATPKgUm0byM',
	RoleList = {		
			['Owner'] = 1175544738586308695,
			['Community Manager'] = 1175544738586308694,
			['Head Developer'] = 1175544738586308692,
			['Developer'] = 1175544738586308691,
			['Head Admin'] = 1175544738586308688,
			['Administator'] = 1175544738569539763,
			['Jr Admin'] = 1175544738569539762,
			['Moderator'] = 1175544738569539761,
			['Staff'] = 1175544738569539759,
			['Server Partner'] = 1175544738569539755,
			['LEO'] = 1175544738548564053,
			['Public Member'] = 1175544738531782812,
	DebugScript = false,
	CacheDiscordRoles = true, -- true to cache player roles, false to make a new Discord Request every time
	CacheDiscordRolesTime = 60, -- if CacheDiscordRoles is true, how long to cache roles before clearing (in seconds)
}

Config.Splash = {
	Header_IMG = 'https://forum-cfx-re.akamaized.net/original/3X/a/6/a6ad03c9fb60fa7888424e7c9389402846107c7e.png',
	Enabled = true,
	Wait = 10, -- How many seconds should splash page be shown for? (Max is 12)
	Heading1 = "Welcome to [ServerName]",
	Heading2 = "Make sure to join our Discord and check out our website!",
	Discord_Link = 'https://discord.gg',
	Website_Link = 'https://badger.store',
}

Read the error message.

You’re missing something on your config.lua around line 22. Usually a comma or something else. It’s a simple fix. If you have any questions dm me on discord dlscripts

Thing is, If I put a comma there, It then throws an error to check the config to ensure everything is correct

You will also now want to regenerate your Discord bot token, as you’ve shared it publicly here.

After the “Public Member” line, you’re missing the closing }. You ned to add this after the Role ID line or on a separate new line.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.