diff --git a/src/main/java/com/rymcu/vertical/service/impl/ArticleServiceImpl.java b/src/main/java/com/rymcu/vertical/service/impl/ArticleServiceImpl.java index ea482ca..6ee4fe4 100644 --- a/src/main/java/com/rymcu/vertical/service/impl/ArticleServiceImpl.java +++ b/src/main/java/com/rymcu/vertical/service/impl/ArticleServiceImpl.java @@ -141,7 +141,7 @@ public class ArticleServiceImpl extends AbstractService
implements Arti newArticle.setArticleStatus(article.getArticleStatus()); articleMapper.insertSelective(newArticle); articleMapper.insertArticleContent(newArticle.getIdArticle(), articleContent, articleContentHtml); - if (!ProjectConstant.ENV.equals(env) && defaultStatus.equals(newArticle.getArticleStatus()) && articleContent.length() > MAX_PREVIEW * 3) { + if (!ProjectConstant.ENV.equals(env) && defaultStatus.equals(newArticle.getArticleStatus()) && articleContent.length() >= MAX_PREVIEW) { BaiDuUtils.sendSEOData(newArticle.getArticlePermalink()); } } else { @@ -155,7 +155,7 @@ public class ArticleServiceImpl extends AbstractService
implements Arti newArticle.setArticleStatus(article.getArticleStatus()); newArticle.setUpdatedTime(new Date()); articleMapper.updateArticleContent(newArticle.getIdArticle(), articleContent, articleContentHtml); - if (!ProjectConstant.ENV.equals(env) && defaultStatus.equals(newArticle.getArticleStatus()) && articleContent.length() > MAX_PREVIEW * 3) { + if (!ProjectConstant.ENV.equals(env) && defaultStatus.equals(newArticle.getArticleStatus()) && articleContent.length() >= MAX_PREVIEW) { BaiDuUtils.sendUpdateSEOData(newArticle.getArticlePermalink()); } }