Skip to content

Commit

Permalink
prevent NPE
Browse files Browse the repository at this point in the history
  • Loading branch information
zlatinb committed Jun 15, 2022
1 parent 6114389 commit 27d37e5
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions gui/src/main/groovy/com/muwire/gui/TrustCellRenderer.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ class TrustCellRenderer extends DefaultTableCellRenderer {
Component getTableCellRendererComponent(JTable table, Object value,
boolean isSelected, boolean hasFocus, int row, int column) {
super.getTableCellRendererComponent(table, value, isSelected, hasFocus, row, column)

if (value == null)
return this // TODO: investigate

TrustLevel level = (TrustLevel) value
switch(value) {
Expand Down

0 comments on commit 27d37e5

Please sign in to comment.