diff --git a/index.js b/index.js index 8c6f6ed..8fcb9af 100644 --- a/index.js +++ b/index.js @@ -2,7 +2,7 @@ Clippy bot for mastodon. - (c) Hugh Rundle, licensed AGPL 3.0+ + (c) Hugh Rundle, licensed AGPL 3.0 or later Contact @hugh@ausglam.space NOTE: Since requesting users must be followed by the bot, they will "out" themselves by using it. @@ -11,7 +11,7 @@ // require modules const axios = require('axios') -const crypto = require('crypto') // built in node module requires v12.19 or higher +const crypto = require('crypto') // built-in node module requires v12.19 or higher const WebSocket = require('ws') // clippy settings @@ -143,7 +143,7 @@ ws.on('message', msg => { if ( data.content.includes(topic) ) { sendResponse(rip, user) } - else if (data.spoiler_text == topic) { + else if (data.spoiler_text.includes(topic)) { sendResponse(rip, user) } else if (data.tags.includes(topic)) { diff --git a/package-lock.json b/package-lock.json index 0f5deef..e35eebd 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "mastodon-clippy", - "version": "0.1.0", + "version": "1.0.1", "lockfileVersion": 1, "requires": true, "dependencies": { diff --git a/package.json b/package.json index d7f04d6..af8ed27 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "mastodon-clippy", - "version": "1.0.0", + "version": "1.0.1", "description": "Mastodon clippy bot", "repository": "https://github.com/hughrun/mastodon-clippy.git", "main": "index.js",