public Result execute(Command command) {
        MessageDTO messageDTO = (MessageDTO) command.getCommandSource();
        List<MessageStatuss> messageStatusses = new ArrayList<MessageStatuss>();
        for (Iterator<MessageStatussDTO> it = messageDTO.getStatus().iterator(); it.hasNext();) {
            MessageStatussDTO messageStatuss1 = it.next();
            MessageStatuss st = new MessageStatuss();
            st.setAcountsSender(accountDAO.getAccountByname(messageStatuss1.getAcountsSender().getAccountName()));
            if (accountDAO.getAccountByname(messageStatuss1.getAccount().getAccountName()) == null) {
                result.setHasError(true);
                result.setError("Account not found");

            }
            st.setAcounts(accountDAO.getAccountByname(messageStatuss1.getAccount().getAccountName()));
            messageStatusses.add(st);
        }

        Message message = new Message();
        message.setBody(messageDTO.getBody());
        message.setTimeStamp(new Date());
        message.setStatus(messageStatusses);
        message.setTitle(messageDTO.getTitle());
        messageDAO.addMessage(message);
        return result;
    }