Change printStackTrace calls to log, move trailing comments to a new/different line, move string literals to the left of a string comparison, return value right away instead of assigning to a variable and then returning it

BMS-80

Reviewer: Mae Turiana