- Sone currentSone = getCurrentSone(request.getToadletContext());
- webInterface.core().createReply(currentSone, post, text);
- throw new RedirectException("viewPost.html?post=" + post.getId());
+ String senderId = request.getHttpRequest().getPartAsStringFailsafe("sender", 43);
+ Sone sender = webInterface.getCore().getLocalSone(senderId, false);
+ if (sender == null) {
+ sender = getCurrentSone(request.getToadletContext());
+ }
+ webInterface.getCore().createReply(sender, post, text);
+ throw new RedirectException(returnPage);