pineafan | 3276721 | 2022-03-14 21:27:39 +0000 | [diff] [blame^] | 1 | const {addLog} = require('../scripts/addLogs'); |
| 2 | const JsonDiff = require('json-diff'); |
| 3 | module.exports = { |
| 4 | name:'stickerUpdate', |
| 5 | once:false, |
| 6 | async execute(oldSticker, newSticker) { |
| 7 | let os = { |
| 8 | id: sticker.id, |
| 9 | description: sticker.description, |
| 10 | name: sticker.name, |
| 11 | type: sticker.type, |
| 12 | tags: sticker.tags, |
| 13 | } |
| 14 | |
| 15 | let ns = { |
| 16 | id: sticker.id, |
| 17 | description: sticker.description, |
| 18 | name: sticker.name, |
| 19 | type: sticker.type, |
| 20 | tags: sticker.tags, |
| 21 | } |
| 22 | |
| 23 | let data = JsonDiff.diff(os, ns, {full: true}); |
| 24 | |
| 25 | addLog(role.guild.id, data); |
| 26 | } |
| 27 | } |