Prevents duplicate messages.