Skip to content

Commit 3075aa2

Browse files
committed
fix: modrinthapp adds an empty line
1 parent b0b19f3 commit 3075aa2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

common/src/main/java/io/github/thebossmagnus/mods/config_manager/common_coremod/compat/ModrinthAppCompat.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
The launcher option will override the pack preference (only for the full screen obv)
1616
To do that we first check if the file, that only "fullscreen:..." exits or not (-1), than we save the status of fullscreen (0 or 1),
1717
delete the file, copy and later reapply it after the copy
18-
*/
18+
*/
1919
public final class ModrinthAppCompat {
2020

2121

@@ -25,10 +25,10 @@ public static int getFullScreenSetting(@NotNull Path gameDir) {
2525
if (Files.exists(gameDir.resolve("options.txt"))) {
2626
try {
2727
String content = Files.readString(gameDir.resolve("options.txt"));
28-
if (content.equals("fullscreen:true")) {
28+
if (content.equals("\nfullscreen:true") || content.equals("fullscreen:true")) {
2929
LOGGER.info("Detected fullscreen preference imposed by the launcher: true, Merging it with modpack preference");
3030
return 1;
31-
} else if (content.equals("fullscreen:false")) {
31+
} else if (content.equals("\nfullscreen:false") || content.equals("fullscreen:false")) {
3232
LOGGER.info("Detected fullscreen preference imposed by the launcher: false, Merging it with modpack preference");
3333
return 0;
3434
}

0 commit comments

Comments
 (0)