Moved organizeTags function over to util method.

We were using it in many places, and it was the same code.  It's a no
brainer to make this a utility method.

TODO:
- Allow someone to pass in @obj.key and that is the key that we set the
  properties on but we return out @obj as a whole.