mirror of
https://github.com/abocn/TelegramBot.git
synced 2025-04-28 09:15:57 +00:00
Update all references to lib-spamwatch
This commit is contained in:
parent
80a0bc08ad
commit
31cfc01f2f
4
.gitmodules
vendored
4
.gitmodules
vendored
@ -1,3 +1,3 @@
|
||||
[submodule "src/plugins/lib-spamwatch"]
|
||||
path = src/plugins/lib-spamwatch
|
||||
[submodule "src/spamwatch"]
|
||||
path = src/spamwatch
|
||||
url = https://github.com/ABOCN/TelegramBot-SpamWatch
|
||||
|
@ -1,7 +1,7 @@
|
||||
const Resources = require('../props/resources.json');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const axios = require("axios");
|
||||
|
||||
module.exports = (bot) => {
|
||||
|
@ -1,7 +1,7 @@
|
||||
const Resources = require('../props/resources.json');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const axios = require('axios');
|
||||
|
||||
async function getDeviceList() {
|
||||
|
@ -1,6 +1,6 @@
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const os = require('os');
|
||||
const { exec } = require('child_process');
|
||||
const { error } = require('console');
|
||||
|
@ -1,7 +1,7 @@
|
||||
const Resources = require('../props/resources.json');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
function sendRandomReply(ctx, gifUrl, textKey) {
|
||||
const Strings = getStrings(ctx.from.language_code);
|
||||
|
@ -4,8 +4,8 @@
|
||||
// With some help from GPT (I don't really like AI but whatever)
|
||||
// If this were a kang, I would not be giving credits to him!
|
||||
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
const axios = require('axios');
|
||||
const { parse } = require('node-html-parser');
|
||||
|
@ -1,6 +1,6 @@
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
async function sendHelpMessage(ctx, isEditing) {
|
||||
const Strings = getStrings(ctx.from.language_code);
|
||||
|
@ -1,7 +1,7 @@
|
||||
const Resources = require('../props/resources.json');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const axios = require('axios');
|
||||
|
||||
module.exports = (bot) => {
|
||||
|
@ -1,6 +1,6 @@
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
async function getUserInfo(ctx) {
|
||||
const Strings = getStrings(ctx.from.language_code);
|
||||
|
@ -2,8 +2,8 @@ const Resources = require('../props/resources.json');
|
||||
const fs = require('fs');
|
||||
const axios = require('axios');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
const scrobbler_url = Resources.lastFmApi;
|
||||
const api_key = process.env.lastKey;
|
||||
|
@ -1,6 +1,6 @@
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
module.exports = (bot) => {
|
||||
bot.start(spamwatchMiddleware, async (ctx) => {
|
||||
|
@ -3,8 +3,8 @@ const axios = require('axios');
|
||||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
async function downloadModule(moduleId) {
|
||||
try {
|
||||
|
@ -1,7 +1,7 @@
|
||||
const Resources = require('../props/resources.json');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const axios = require("axios");
|
||||
|
||||
function capitalizeFirstLetter(string) {
|
||||
|
@ -1,7 +1,7 @@
|
||||
// const Resources = require('../props/resources.json');
|
||||
// const { getStrings } = require('../plugins/checklang.js');
|
||||
// const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
// const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
// const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
// const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
// const escape = require('markdown-escape');
|
||||
// const axios = require('axios');
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
const Resources = require('../props/resources.json');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const axios = require("axios");
|
||||
|
||||
module.exports = (bot) => {
|
||||
|
@ -5,8 +5,8 @@
|
||||
const Resources = require('../props/resources.json');
|
||||
const axios = require('axios');
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
|
||||
const statusEmojis = {
|
||||
0: '⛈', 1: '⛈', 2: '⛈', 3: '⛈', 4: '⛈', 5: '🌨', 6: '🌨', 7: '🌨',
|
||||
|
@ -1,6 +1,6 @@
|
||||
const { getStrings } = require('../plugins/checklang.js');
|
||||
const { isOnSpamWatch } = require('../plugins/lib-spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../plugins/lib-spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { isOnSpamWatch } = require('../spamwatch/spamwatch.js');
|
||||
const spamwatchMiddleware = require('../spamwatch/Middleware.js')(isOnSpamWatch);
|
||||
const { execFile } = require('child_process');
|
||||
const os = require('os');
|
||||
const fs = require('fs');
|
||||
|
@ -1 +0,0 @@
|
||||
Subproject commit 8d35b7ec4cffb48df8d1f59485b32e2484ae64e7
|
1
src/spamwatch
Submodule
1
src/spamwatch
Submodule
@ -0,0 +1 @@
|
||||
Subproject commit b71b3b9eab0f172c038674fc6739fce9199ad3e0
|
Loading…
x
Reference in New Issue
Block a user