fix and restrict chat message length