Refine logging

This commit is contained in:
Reinhard Pointner 2016-03-12 16:42:09 +00:00
parent 1c95bfd16a
commit 346bd69ff1
3 changed files with 3 additions and 5 deletions

View File

@ -111,7 +111,7 @@ class EpisodeListMatcher implements AutoCompleteMatcher {
prefs.put("dialog.select.h", Integer.toString(selectDialog.getHeight()));
if (selectDialog.getSelectedAction() == null) {
throw new CancellationException("Cancelled by user");
throw new CancellationException();
}
// remember if we should auto-repeat the chosen action in the future

View File

@ -427,7 +427,7 @@ class MovieHashMatcher implements AutoCompleteMatcher {
}
if (selectDialog.getSelectedAction() == null) {
throw new CancellationException("Cancelled by user");
throw new CancellationException();
}
// selected value or null if the dialog was canceled by the user

View File

@ -888,9 +888,7 @@ public class RenamePanel extends JComponent {
// add remaining file entries
renameModel.files().addAll(remainingFiles);
} catch (Exception e) {
if (findCause(e, CancellationException.class) != null) {
debug.log(Level.WARNING, getRootCause(e).toString());
} else {
if (findCause(e, CancellationException.class) == null) {
log.log(Level.WARNING, String.format("%s: %s", getRootCause(e).getClass().getSimpleName(), getRootCauseMessage(e)), e);
}
} finally {