you should check message length. see task description.