Skip to content

Commit c9d79ca

Browse files
author
jan
committed
add extra logging for debugging
1 parent 26ad25c commit c9d79ca

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

io.sloeber.core/src/io/sloeber/core/tools/TxtFile.java

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,12 +62,21 @@ public TxtFile(File boardsFileName, boolean workAround) {
6262

6363
this.mLastLoadedTxtFile =boardsFileName;
6464
File actuallyLoadedTxtFile = mLastLoadedTxtFile;
65+
// If the file doesn't exist ignore it.
66+
if (!boardsFileName.exists()) {
67+
return ;
68+
}
69+
6570
if(workAround) {
6671
actuallyLoadedTxtFile =WorkAround.MakeBoardsSloeberTxt(boardsFileName);
6772
}
68-
// If the file doesn't exist ignore it.
69-
if (!actuallyLoadedTxtFile.exists())
73+
74+
if (!actuallyLoadedTxtFile.exists()) {
75+
Common.log(new Status(IStatus.ERROR, Const.CORE_PLUGIN_ID,
76+
"TXT worked around file " +actuallyLoadedTxtFile.getName() + " does not exist.")); //$NON-NLS-1$ //$NON-NLS-2$
7077
return ;
78+
}
79+
7180

7281
this.fileContent.clear();
7382

0 commit comments

Comments
 (0)