Buggy code:
@ DefaultValue ( "NONE" ) final AuditMode auditMode , @ javax . ws . rs . core . Context final HttpServletRequest request ) throws SubscriptionApiException { } @ TimedResource @ POST @ Consumes ( MediaType . APPLICATION_JSON ) @ Produces ( MediaType . APPLICATION_JSON ) @ ApiOperation ( value = "Trigger<seq2seq4repair_space>an<seq2seq4repair_space>invoice<seq2seq4repair_space>generation" , response = InvoiceJson . class ) @ ApiResponses ( { @ ApiResponse ( code = 400 , message = "Invalid<seq2seq4repair_space>account<seq2seq4repair_space>id<seq2seq4repair_space>or<seq2seq4repair_space>target<seq2seq4repair_space>datetime<seq2seq4repair_space>supplied" ) } ) public Response createFutureInvoice ( @ QueryParam ( QUERY_ACCOUNT_ID ) final String accountId , @ QueryParam ( QUERY_TARGET_DATE ) final String targetDate , @ HeaderParam ( HDR_CREATED_BY ) final String createdBy , @ HeaderParam ( HDR_REASON ) final String reason , @ HeaderParam ( HDR_COMMENT ) final String comment , @ javax . ws . rs . core . Context final HttpServletRequest request , @ javax . ws . rs . core . Context final UriInfo uriInfo ) throws AccountApiException , InvoiceApiException { } @ TimedResource @ POST @ Path ( ( ( ( "//" + ( MIGRATION ) ) + "//{accountId:" ) + ( UUID_PATTERN ) ) + "}" ) @ Consumes ( MediaType . APPLICATION_JSON ) @ Produces ( MediaType . APPLICATION_JSON ) @ ApiOperation ( value = "Create<seq2seq4repair_space>a<seq2seq4repair_space>migration<seq2seq4repair_space>invoice" , response = InvoiceJson . class ) @ ApiResponses ( { @ ApiResponse ( code = 400 , message = "Invalid<seq2seq4repair_space>account<seq2seq4repair_space>id<seq2seq4repair_space>or<seq2seq4repair_space>target<seq2seq4repair_space>datetime<seq2seq4repair_space>supplied" ) } ) public Response createMigrationInvoice ( final Iterable < InvoiceItemJson > items , @ PathParam ( "accountId" ) final String accountId , @ Nullable @ QueryParam ( QUERY_TARGET_DATE ) final String targetDate , @ HeaderParam ( HDR_CREATED_BY ) final String createdBy , @ HeaderParam ( HDR_REASON ) final String reason , @ HeaderParam ( HDR_COMMENT ) final String comment , @ javax . ws . rs . core . Context final HttpServletRequest request , @ javax . ws . rs . core . Context final UriInfo uriInfo ) throws AccountApiException , InvoiceApiException { } @ TimedResource @ POST @ Path ( "//" + ( DRY_RUN ) ) @ Consumes ( MediaType . APPLICATION_JSON ) @ Produces ( MediaType . APPLICATION_JSON ) @ ApiOperation ( value = "Generate<seq2seq4repair_space>a<seq2seq4repair_space>dryRun<seq2seq4repair_space>invoice" , response = InvoiceJson . class ) @ ApiResponses ( { @ ApiResponse ( code = 400 , message = "Invalid<seq2seq4repair_space>account<seq2seq4repair_space>id<seq2seq4repair_space>or<seq2seq4repair_space>target<seq2seq4repair_space>datetime<seq2seq4repair_space>supplied" ) } ) public Response generateDryRunInvoice ( @ Nullable final InvoiceDryRunJson dryRunSubscriptionSpec , @ QueryParam ( QUERY_ACCOUNT_ID ) final String accountId , @ Nullable @ QueryParam ( QUERY_TARGET_DATE ) final String targetDate , @ HeaderParam ( HDR_CREATED_BY ) final String createdBy , @ HeaderParam ( HDR_REASON ) final String reason , @ HeaderParam ( HDR_COMMENT ) final String comment , @ javax . ws . rs . core . Context final HttpServletRequest request , @ javax . ws . rs . core . Context final UriInfo uriInfo ) throws AccountApiException , InvoiceApiException { } @ TimedResource @ DELETE @ Path ( ( ( ( ( "//{invoiceId:" + ( UUID_PATTERN ) ) + "}" ) + "//{invoiceItemId:" ) + ( UUID_PATTERN ) ) + "}//cba" ) @ Consumes ( MediaType . APPLICATION_JSON ) @ Produces ( MediaType . APPLICATION_JSON ) @ ApiOperation ( "Delete<seq2seq4repair_space>a<seq2seq4repair_space>CBA<seq2seq4repair_space>item" ) @ ApiResponses ( { @ ApiResponse ( code = 400 , message = "Invalid<seq2seq4repair_space>account<seq2seq4repair_space>id,<seq2seq4repair_space>invoice<seq2seq4repair_space>id<seq2seq4repair_space>or<seq2seq4repair_space>invoice<seq2seq4repair_space>item<seq2seq4repair_space>id<seq2seq4repair_space>supplied" ) , @ ApiResponse ( code = 404 , message = "Account<seq2seq4repair_space>or<seq2seq4repair_space>invoice<seq2seq4repair_space>not<seq2seq4repair_space>found" ) } ) public Response deleteCBA ( @ PathParam ( "invoiceId" ) final String invoiceId , @ PathParam ( "invoiceItemId" ) final String invoiceItemId , @ QueryParam ( QUERY_ACCOUNT_ID ) final String accountId , @ HeaderParam ( HDR_CREATED_BY ) final String createdBy , @ HeaderParam ( HDR_REASON ) final String reason , @ HeaderParam ( HDR_COMMENT ) final String comment , @ javax . ws . rs . core . Context final HttpServletRequest request ) throws AccountApiException , InvoiceApiException { } @ TimedResource @ POST @ Path ( ( "//{invoiceId:" + ( UUID_PATTERN ) ) + "}" ) @ Consumes ( MediaType . APPLICATION_JSON ) @ Produces ( MediaType . APPLICATION_JSON ) @ ApiOperation ( "Adjust<seq2seq4repair_space>an<seq2seq4repair_space>invoice<seq2seq4repair_space>item" ) @ ApiResponses ( { @ ApiResponse ( code = 400 , message = "Invalid<seq2seq4repair_space>account<seq2seq4repair_space>id,<seq2seq4repair_space>invoice<seq2seq4repair_space>id<seq2seq4repair_space>or<seq2seq4repair_space>invoice<seq2seq4repair_space>item<seq2seq4repair_space>id<seq2seq4repair_space>supplied" ) , @ ApiResponse ( code = 404 , message = "Invoice<seq2seq4repair_space>not<seq2seq4repair_space>found" ) } ) public Response adjustInvoiceItem ( final InvoiceItemJson json , @ PathParam ( "invoiceId" ) final String invoiceId , @ QueryParam ( QUERY_REQUESTED_DT ) final String requestedDateTimeString , @ HeaderParam ( HDR_CREATED_BY ) final String createdBy , @ HeaderParam ( HDR_REASON ) final String reason , @ HeaderParam ( HDR_COMMENT ) final String comment , @ javax . ws . rs . core . Context final HttpServletRequest request , @ javax . ws . rs . core . Context final UriInfo uriInfo ) throws AccountApiException , InvoiceApiException { } @ TimedResource @ POST @ Produces ( MediaType . APPLICATION_JSON ) @ Consumes ( MediaType . APPLICATION_JSON ) @ Path ( ( ( ( "//" + ( CHARGES ) ) + "//{accountId:" ) + ( UUID_PATTERN ) ) + "}" ) @ ApiOperation ( value = "Create<seq2seq4repair_space>external<seq2seq4repair_space>charge(s)" , response = InvoiceItemJson . class , responseContainer = "List" ) @ ApiResponses ( { @ ApiResponse ( code = 400 , message = "Invalid<seq2seq4repair_space>account<seq2seq4repair_space>id<seq2seq4repair_space>supplied" ) , @ ApiResponse ( code = 404 , message = "Account<seq2seq4repair_space>not<seq2seq4repair_space>found" ) } ) public Response createExternalCharges ( final Iterable < InvoiceItemJson > externalChargesJson , @ PathParam ( "accountId" ) final String accountId , @ QueryParam ( QUERY_REQUESTED_DT ) final String requestedDateTimeString , @ QueryParam ( QUERY_PAY_INVOICE ) @ DefaultValue ( "false" ) final Boolean payInvoice , @ QueryParam ( QUERY_PLUGIN_PROPERTY ) final List < String > pluginPropertiesString , @ HeaderParam ( HDR_CREATED_BY ) final String createdBy , @ HeaderParam ( HDR_REASON ) final String reason , @ HeaderParam ( HDR_COMMENT ) final String comment , @ javax . ws . rs . core . Context final UriInfo uriInfo , @ javax . ws . rs . core . Context final HttpServletRequest request ) throws AccountApiException , InvoiceApiException , PaymentApiException { } private Iterable < InvoiceItem > validateSanitizeAndTranformInputItems ( final Currency accountCurrency , final Iterable < InvoiceItemJson > inputItems ) throws InvoiceApiException { try { final Iterable < InvoiceItemJson > sanitized = Iterables . transform ( inputItems , new Function < InvoiceItemJson , InvoiceItemJson > ( ) { @ Override public InvoiceItemJson apply ( final InvoiceItemJson input ) { if ( ( input . getCurrency ( ) ) != null ) { <START_BUG> if ( ! ( input . getCurrency ( ) . equals ( accountCurrency ) ) ) { <END_BUG>

Fix:
if ( ! ( input . getCurrency ( ) . equals ( accountCurrency . name ( ) ) ) ) {