File tree Expand file tree Collapse file tree 4 files changed +26
-4
lines changed Expand file tree Collapse file tree 4 files changed +26
-4
lines changed Original file line number Diff line number Diff line change 1
1
OpenBLCMM Changelog
2
2
===================
3
3
4
+ ** v1.3.3** May 26, 2023
5
+ - Fixed a startup crash issue for Windows users whose system username has a
6
+ @domain suffix which isn't present in their homedir.
7
+
4
8
** v1.3.2** May 24, 2023
5
9
- Fixed TPS Game Detection on Windows
6
10
- Importing mods via drag-and-drop will correctly update OpenBLCMM's "last
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ public class Meta {
44
44
/**
45
45
* App version. Should follow https://semver.org/ conventions.
46
46
*/
47
- public static final String VERSION = "1.3.2 " ;
47
+ public static final String VERSION = "1.3.3 " ;
48
48
49
49
/**
50
50
* User data directory for storing prefs, extracted data, etc. If NAME
Original file line number Diff line number Diff line change @@ -184,8 +184,26 @@ public static String hideUserName(String text) {
184
184
return text .replace (userHome , "~" );
185
185
} else {
186
186
String userName = System .getProperty ("user.name" );
187
- String replaced = userHome .substring (0 , userHome .length () - userName .length ()) + "[user]" ;
188
- return text .replace (userHome , replaced );
187
+ //GlobalLogger.log("user.home: '" + userHome + "'");
188
+ //GlobalLogger.log("user.name: '" + userName + "'");
189
+ if (!userHome .endsWith (userName ) && userName .contains ("@" )) {
190
+ // Sometimes a user might have "@outlook" as part of their username
191
+ // which isn't included in the homedir. There's probably a better
192
+ // way to be checking for this.
193
+ String [] parts = userName .split ("@" , 2 );
194
+ userName = parts [0 ];
195
+ }
196
+ // This is sort of a double check of the same values in most cases,
197
+ // but whatever.
198
+ if (userHome .endsWith (userName )) {
199
+ String replaced = userHome .substring (0 , userHome .length () - userName .length ()) + "[user]" ;
200
+ return text .replace (userHome , replaced );
201
+ } else {
202
+ // Username wasn't found in the homedir, so just give up
203
+ // (this logging would be a bit noisy; not bothering with it)
204
+ //GlobalLogger.log("Could not figure out how to hide username in homedir!");
205
+ return text ;
206
+ }
189
207
}
190
208
}
191
209
return text ;
Original file line number Diff line number Diff line change 2
2
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!
3
3
4
4
#define MyAppName " OpenBLCMM"
5
- #define MyAppVersion " 1.3.2 "
5
+ #define MyAppVersion " 1.3.3 "
6
6
#define MyAppPublisher " BLCM"
7
7
#define MyAppURL " https://github.com/BLCM/OpenBLCMM/"
8
8
#define MyAppExeName " OpenBLCMM.exe"
You can’t perform that action at this time.
0 commit comments