Skip to content

请问是否有办法设置不收集评论者的IP、UA和所属地信息? #1315

Answered by lizheming
493490561 asked this question in Q&A
Discussion options

You must be logged in to vote

可以自定义钩子实现 https://waline.js.org/reference/server.html#presave-comment

// index.js 
const Waline = require('@waline/vercel');
module.exports = Waline({
  preSave(data) {
    delete data.ua;
    delete data.ip;
  }
});

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@493490561
Comment options

Answer selected by lizheming
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants