// Step 12: Set post to community
final boolean postToCommunity = article.optBoolean(Common.POST_TO_COMMUNITY, true);
article.remove(Common.POST_TO_COMMUNITY); // Do not persist this property
// Setp 13: Update user article statistic
final JSONObject author = userRepository.getByEmail(article.optString(Article.ARTICLE_AUTHOR_EMAIL));
final int userArticleCnt = author.optInt(UserExt.USER_ARTICLE_COUNT);
author.put(UserExt.USER_ARTICLE_COUNT, userArticleCnt + 1);
if (article.optBoolean(Article.ARTICLE_IS_PUBLISHED)) {
author.put(UserExt.USER_PUBLISHED_ARTICLE_COUNT, author.optInt(UserExt.USER_PUBLISHED_ARTICLE_COUNT) + 1);
}
userRepository.update(author.optString(Keys.OBJECT_ID), author);