added comment to @ljo's earlier fix for handling chars A and up, adapted the fix to match the form of @jsnelson's original conditional logic
Adding comment and also performance refactoring by Michael Westbay.
Merge pull request #6 from ljo/fix-decodeHexChar