<commit_before>package com.nutomic.syncthingandroid.model;

import android.text.TextUtils;

import java.util.List;

public class Device {
    public String deviceID;
    public String name;
    public List<String> addresses;
    public String compression;
    public String certName;
    public boolean introducer;
    public boolean paused;

    /**
     * Returns the device name, or the first characters of the ID if the name is empty.
     */
    public String getDisplayName() {
        return (TextUtils.isEmpty(name))
                ? deviceID.substring(0, 7)
                : name;
    }
}
<commit_msg>Fix DeviceListFragment NPE on Comparator (#20)<commit_after>package com.nutomic.syncthingandroid.model;

import android.text.TextUtils;

import java.util.List;

public class Device {
    public String deviceID;
    public String name = "";
    public List<String> addresses;
    public String compression;
    public String certName;
    public boolean introducer;
    public boolean paused;

    /**
     * Returns the device name, or the first characters of the ID if the name is empty.
     */
    public String getDisplayName() {
        return (TextUtils.isEmpty(name))
                ? deviceID.substring(0, 7)
                : name;
    }
}

{'fraction_non_alphanumeric': 0.08082408874801902, 'fraction_numerical': 0.004754358161648178, 'mean_word_length': 2.6502890173410405, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3749916', 'n_tokens_mistral': 351, 'n_tokens_neox': 339, 'n_words': 113}