[ https://issues.apache.org/jira/browse/CODEC-256?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16852929#comment-16852929 ]
Melloware commented on CODEC-256: --------------------------------- [~aschnur] I am creating a GitHub PR for your change. You change works however one of the previous unit tests fails and I want to confirm it is failing. Right now it has.. hoffmann=0366 And with your fix it now reports it should be... hoffmann=036 Can you confirm this is correct? > ColognePhonetic.encode() calculates wrong code > ---------------------------------------------- > > Key: CODEC-256 > URL: https://issues.apache.org/jira/browse/CODEC-256 > Project: Commons Codec > Issue Type: Bug > Affects Versions: 1.12 > Environment: Java 8u181 64, Windows 7 Professional 64 > Reporter: Andreas Schnur > Priority: Major > Attachments: ColognePhonetic.java > > > Example String: "ARTMANN". Code of M is 6, Code of A is Zero (and therefore > is left out), Code of N is 6 and should be left out because 6 is previous, > but Code assumes wrongly 0 as previous (which was left out). So the result is > 07266, but has to be 0726 (see Description of algorithm in class). > Solution: In method colognePhonetic() move the last two LOC into if-block > above, see attached version of class. -- This message was sent by Atlassian JIRA (v7.6.3#76005)