mirror of
https://gitlab.com/oeffi/public-transport-enabler.git
synced 2025-07-07 23:08:50 +00:00
fixed NPE if no label
git-svn-id: https://public-transport-enabler.googlecode.com/svn/trunk@739 0924bc21-9374-b0fa-ee44-9ff1593b38f0
This commit is contained in:
parent
24da6ec2e9
commit
1bfd8ffc12
1 changed files with 2 additions and 2 deletions
|
@ -31,7 +31,7 @@ public final class Line implements Serializable, Comparable<Line>
|
|||
final public String label;
|
||||
final public int[] colors;
|
||||
|
||||
private static final String PRODUCT_ORDER = "IRSUTBPFC";
|
||||
private static final String PRODUCT_ORDER = "IRSUTBPFC?";
|
||||
|
||||
public Line(final String id, final String label, final int[] colors)
|
||||
{
|
||||
|
@ -39,7 +39,7 @@ public final class Line implements Serializable, Comparable<Line>
|
|||
this.label = label;
|
||||
this.colors = colors;
|
||||
|
||||
product = label.charAt(0);
|
||||
product = label != null ? label.charAt(0) : '?';
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue