messages association renamed to sent_messages
user association renamed to sender
specify class_name in sender association
many-to-many association between user and message