boofiboi / FiveM-Discord-Presence

FiveM resource to get your server a nice customized Discord rich presence.
GNU General Public License v2.0
12 stars 6 forks source link

[BUG] Error in console #8

Closed operationairstrike closed 1 month ago

operationairstrike commented 1 month ago

Yo the 1.9 didnt fix it, now i get: [ script:discord] SCRIPT ERROR: @discord/server/server.lua:12: attempt to compare string with nil [ script:discord] > userCallback (@discord/server/server.lua:12)

boofiboi commented 1 month ago

do you even have VERSION in the script folder...

operationairstrike commented 1 month ago

I have all files sir

operationairstrike commented 1 month ago

Do you want a screenshot 😂

operationairstrike commented 1 month ago

grafik

operationairstrike commented 1 month ago

folder name is discord

operationairstrike commented 1 month ago

does it matter?

boofiboi commented 1 month ago

Yes it does. It needs to be "FiveM-Discord-Presence" or else Line 7 returns nil and there's your issue.

operationairstrike commented 1 month ago

I'm really sorry. Thanks for the fixes tho. I will rename it on line 7, I guess?

operationairstrike commented 1 month ago

I was thinking about this yesterday, and i think it's true that it's 99% of the time the user that is too dumb to use it and not the code.😂💀

operationairstrike commented 1 month ago

Yo you may add a line to the readme so that people know.

boofiboi commented 1 month ago

It's not the user, its me.

I coded it with hardcoded variables.

operationairstrike commented 1 month ago

Fair point I thought about using $PATH somehow to automatically get the path it's in yk. That would be awesome tbh.

operationairstrike commented 4 weeks ago

I changed it and there's seems to be no error now

operationairstrike commented 4 weeks ago

I suggest using $PATH in the code