Closed mani1232 closed 1 year ago
Well, I don't know exactly why because I cannot debug all the project, but I can try to give you some tips.
Have you checked the content of the file?
It generated by lib https://github.com/mani1232/CustomBot/blob/dev-full-refactor/src/main/java/ua/mani123/config/ConfigUtils.java#L23 But if im read this file by lib it return null, and how return empty list, not null
it is generated only if it doesn't exist, maybe an older version of the file is still there?
[[DiscordBot]]
BotId = 0
BotToken = "TOKEN_CHANGE_IT_1"
[[DiscordBot]]
BotId = 1
BotToken = "TOKEN_CHANGE_IT_2"
[[DiscordBot]]
BotId = 2
BotToken = "TOKEN_CHANGE_IT_3"
No, it latest
im fix it, im dont know why builder return null config, now im use parser
I think that the problem was: you forgot to call config.load()
This null: https://github.com/mani1232/CustomBot/blob/dev-full-refactor/src/main/java/ua/mani123/config/Objects/BotConfig.java#L17 But creating with default is fine, and after convert back to object set list to null: https://github.com/mani1232/CustomBot/blob/dev-full-refactor/src/main/java/ua/mani123/config/ConfigUtils.java#L17