Skip to content

Commit

Permalink
Fix NPE, which triggered when 'Show variable details' reverted to the…
Browse files Browse the repository at this point in the history
… default value, when PreferenceChangeEvent.newValue is actually null
  • Loading branch information
gzsombor authored and iloveeclipse committed Oct 1, 2022
1 parent 119ab72 commit 11fb0a6
Showing 1 changed file with 6 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -220,16 +220,12 @@ protected void retrieveLabel(ILabelUpdate update) throws CoreException {
* @param value preference value for PREF_SHOW_DETAILS
*/
private void determineSerializationMode(String value) {
switch (value) {
case IJDIPreferencesConstants.INLINE_ALL:
fSerializeMode = SERIALIZE_NONE;
break;
case IJDIPreferencesConstants.INLINE_FORMATTERS:
fSerializeMode = SERIALIZE_SOME;
break;
default:
fSerializeMode = SERIALIZE_ALL;
break;
if (IJDIPreferencesConstants.INLINE_ALL.equals(value)) {
fSerializeMode = SERIALIZE_NONE;
} else if (IJDIPreferencesConstants.INLINE_FORMATTERS.equals(value)) {
fSerializeMode = SERIALIZE_SOME;
} else {
fSerializeMode = SERIALIZE_ALL;
}
}

Expand Down

0 comments on commit 11fb0a6

Please sign in to comment.