Bugfix: When sending a SMS, 'class' is omitted if specified
Reformat code