Cleaning up the code

Made several small changes to clean up the code. Used more idiomatic ruby in some places. Also, used a regex to better match signal data in case the message has stuff like double blank spaces.