- webInterface.getCore().createPost(currentSone, recipient, System.currentTimeMillis(), text);
+ Optional<Sone> sender = webInterface.getCore().getLocalSone(senderId);
+ if (sender == null) {
+ sender = of(currentSone);
+ }
+ Optional<Sone> recipient = webInterface.getCore().getSone(recipientId);
+ text = TextFilter.filter(request.getHttpRequest().getHeader("host"), text);
+ sender.get().newPostBuilder().to(recipient.transform(Identified.GET_ID)).withText(text).build(webInterface.getCore().postCreated());