Compare commits

...

3 Commits

Author SHA1 Message Date
e5f83ec639 Remove duplicate "Sää" strings 2025-08-03 21:22:33 +03:00
5495549464 Fix matching bug with mastodon 2025-08-03 21:22:20 +03:00
960e43ac9b Update packages 2025-08-03 21:22:01 +03:00
4 changed files with 1692 additions and 3238 deletions

4874
package-lock.json generated

File diff suppressed because it is too large Load Diff

View File

@ -14,28 +14,28 @@
"url": "https://lanxu@bitbucket.org/lanxu/kulmapaikka-ircbot"
},
"dependencies": {
"chance": "=1.0.18",
"cheerio": "^1.0.0-rc.2",
"cron": "=1.7.1",
"file-stream-rotator": "=0.4.1",
"finalhandler": "=1.1.2",
"googleapis": "^91.0.0",
"html-to-text": "=5.1.1",
"chance": "=1.1.13",
"cheerio": "^1.1.2",
"cron": "=4.3.3",
"file-stream-rotator": "=1.0.0",
"finalhandler": "=2.1.0",
"googleapis": "^154.1.0",
"html-to-text": "=9.0.5",
"irc": "=0.5.2",
"lokijs": "=1.5.7",
"mkdirp": "=0.5.5",
"morgan": "=1.9.1",
"node-cron": "^2.0.3",
"node-dev": "^7.1.0",
"lokijs": "=1.5.12",
"mkdirp": "=3.0.1",
"morgan": "=1.10.1",
"node-cron": "^4.2.1",
"node-dev": "^8.0.0",
"node-uuid": "=1.4.8",
"promise": "=8.0.3",
"promise": "=8.3.0",
"request": "=2.88.0",
"request-promise": "=4.2.4",
"twitter": "=1.7.1",
"winston": "=3.2.1",
"winston-daily-rotate-file": "^3.10.0"
"winston": "=3.17.0",
"winston-daily-rotate-file": "^5.0.0"
},
"devDependencies": {
"nodemon": "^2.0.15"
"nodemon": "^3.1.10"
}
}

View File

@ -9,10 +9,10 @@ class Mastodon extends BasePlugin {
}
test(input) {
if (input.match(/http(s)?:\/\/(www\.)?((.*\..*\/users\/([a-zA-Z0-9_-]*)\/statuses\/([0-9_-]*)))/)) {
if (input.match(/http(s)?:\/\/(www\.)?((.*\..*\/users\/([a-zA-Z0-9_-]*)\/statuses\/([0-9_-]*)))$/)) {
return true
}
if (input.match(/http(s)?:\/\/(www\.)?(((.*\..*)\/@([a-zA-Z0-9_-]*)\/([0-9_-]*)))/)) {
if (input.match(/http(s)?:\/\/(www\.)?(((.*\..*)\/@([a-zA-Z0-9_-]*)\/([0-9_-]*)))$/)) {
return true
}
return false

View File

@ -177,7 +177,7 @@ class Weather extends BasePlugin {
var windspeed = result.wind.speed
let str = 'Sää: ' + city + ', ' + country + ' (' + temp + ' °C, ' + that.iconCodeToText[code] + ', ilmankosteus: ' + humidity + ' %, ilmanpaine: ' + pressure + ' hPa, tuulen nopeus: ' + windspeed + ' m/s)'
let str = city + ', ' + country + ' (' + temp + ' °C, ' + that.iconCodeToText[code] + ', ilmankosteus: ' + humidity + ' %, ilmanpaine: ' + pressure + ' hPa, tuulen nopeus: ' + windspeed + ' m/s)'
resolve('Sää: ' + str)
}
}, function (error) {