putting compare back to post for rails