I am parsing a generated email to pluck out specific Change Request #'s
When a new email comes in (with a subject line match)
Convert the body of the email to simple text using HTML To Text action
Use IndexOf() to locate anchor text to pluck out the value.
For example, to pluck out the Change Request # for Linux from the email body text:
Linux Change Request: CHG0099999 <<<< note there are two spaces after the colon
I wrote a Compose statement to get the position of the anchor text:
indexOf(body('Html_to_text'),'Linux Change Request: ') <<<two spaces after colon
It returns a -1 when the search text ends in a double space.
If I get rid of the 2nd space it works (gets a match and returns the string's position)
Is this a bug in the software? Something about double-spaces in IndexOf() search parameter that it doesn't like?