Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 57f364ca authored by András Veres-Szentkirályi's avatar András Veres-Szentkirályi
Browse files

combined nested if statements in MimeHeader.hasToBeEncoded

parent f79b1eb1
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -122,12 +122,11 @@ public class MimeHeader {
    public boolean hasToBeEncoded(String text) {
        for (int i = 0; i < text.length(); i++) {
            char c = text.charAt(i);
            if (c < 0x20 || 0x7e < c) { // non printable
                if (c != 0x0a && c != 0x0d && c != 0x09) { // non LF/CR/TAB
            if ((c < 0x20 || 0x7e < c) && // non printable
                    (c != 0x0a && c != 0x0d && c != 0x09)) { // non LF/CR/TAB
                return true;
            }
        }
        }

        return false;
    }