Recently, I was trying to get something in our Mirth Integration Engine working. A project that was behind for a variety of reasons.
I was exhausted, and stressed when co-workers heard me exclaim:
WTF do you mean its undeclared! Its declared right there you stupid machine!!!
I waved my fist at the monitor in a threatening manner, yet this infernal contraption kept telling me “variable mytpe undeclared in line 936″
I thought of EVERYTHING! I checked to see if scope was the issue, I was pretty sure it wasn’t. I thought maybe its a datatype thing, which made no sense at all…
Finally, in a fit of frustrated rage I walked away, grabbed a coffee, and paced around for a bit before going back to it.
I then took another look at the code
var mtype = msg['MSH']['MSH.10']['MSH.10.1'].toString(); if (mytpe.indexOf('D') > -1) { }
I checked everything except spelling!
There’s a few minutes of my life I’ll never get back.