You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I personally use it to read another file, adjacent to the main config file, that contains secrets. One doesn't want to put secrets in the main config, as they are synced to the client!
However, there currently isn't a way (AFAIK) to determine whether the config file is being synced from disk over the network. As a result, there's no way to tell if getFullPath will throw. On 1.20.1, one could poke the config file directly, but as of #178 that's no longer possible, and you have to try/catch the error instead. Ugly!
It would be nice if we just changed getFullPath to be nullable, rather than throwing an exception.
The text was updated successfully, but these errors were encountered:
ModConfig.getFullPath
currently has a comment on it wondering whether it's worth removing.FancyModLoader/loader/src/main/java/net/neoforged/fml/config/ModConfig.java
Lines 64 to 65 in 05a7b82
I personally use it to read another file, adjacent to the main config file, that contains secrets. One doesn't want to put secrets in the main config, as they are synced to the client!
However, there currently isn't a way (AFAIK) to determine whether the config file is being synced from disk over the network. As a result, there's no way to tell if
getFullPath
will throw. On 1.20.1, one could poke the config file directly, but as of #178 that's no longer possible, and you have totry
/catch
the error instead. Ugly!It would be nice if we just changed
getFullPath
to be nullable, rather than throwing an exception.The text was updated successfully, but these errors were encountered: