CodeSOD: This or That
Processing financial transactions is not the kind of software you want to make mistakes in. If something is supposed to happen, it is definitely supposed to happen. Not partially happen. Not maybe happen.
Thus, a company like Charles R's uses a vendor-supplied accounting package. That vendor has a professional services team, so when the behavior needs to be customized, Charles's company outsources that development to the vendor.
Of course, years later, that code needs to get audited, and it's about then that you find out that the vendor outsourced their "professional services" to the lowest bidder, creating a less-than-professional service result.
If you want to make sure than when the country code is equal to "HND", you want to be really sure.
if(transaction.country == config.country_code.HND || transaction.country == config.country_code.HND) parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, ",");else parts[0] = parts[0].replace(/\B(?=(\d{3})+(?!\d))/g, ".");[Advertisement] Application Release Automation for DevOps - integrating with best of breed development tools. Free for teams with up to 5 users. Download and learn more today!