Changeset 13650 in josm


Ignore:
Timestamp:
2018-04-19T23:04:48+02:00 (11 months ago)
Author:
Don-vip
Message:

see #16204 - fix unit test, checkstyle

Location:
trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/io/protocols/data/Handler.java

    r13647 r13650  
    66import java.net.URLConnection;
    77import java.net.URLStreamHandler;
     8import java.util.Optional;
    89
    910import org.openstreetmap.josm.tools.Utils;
     
    3132
    3233        String protocolHandlers = Utils.getSystemProperty("java.protocol.handler.pkgs");
    33         if (protocolHandlers != null && !protocolHandlers.contains(pkg)) {
    34             StringBuilder sb = new StringBuilder(protocolHandlers);
     34        if (protocolHandlers == null || !protocolHandlers.contains(pkg)) {
     35            StringBuilder sb = new StringBuilder(Optional.ofNullable(protocolHandlers).orElse(""));
    3536            if (sb.length() > 0) {
    3637                sb.append('|');
  • trunk/tools/checkstyle/josm_checks.xml

    r13227 r13650  
    113113  <module name="FileLength">
    114114    <property name="fileExtensions" value=".java"/>
     115    <property name="max" value="2500"/>
    115116  </module>
    116117  <module name="FileTabCharacter"/>
Note: See TracChangeset for help on using the changeset viewer.