in util/src/main/java/org/apache/jsieve/util/check/ScriptCheckMailAdapter.java [140:159]
public List<String> getHeader(String name) throws SieveMailException {
List<String> result = Collections.EMPTY_LIST;
if (mail != null) {
try {
String[] values = mail.getHeader(name);
if (values != null) {
// We need to do unfold headers + decoding here
result = new LinkedList<String>();
for (String value: values) {
result.add(MimeUtility.decodeText(MimeUtility.unfold(value)));
}
}
} catch (MessagingException e) {
throw new SieveMailException(e);
} catch (UnsupportedEncodingException e) {
throw new SieveMailException(e);
}
}
return result;
}