1
0
mirror of https://github.com/azlux/botamusique synced 2024-11-23 22:06:09 +00:00

Compare commits

..

4 Commits

Author SHA1 Message Date
Terry Geng
f9cc9c7872
Merge pull request #272 from mweinelt/catch-indexerror-on-empty-message
Don't assume text messages have a first character in command parsing
2021-05-16 09:06:48 +08:00
Martin Weinelt
e6592f5c22
Don't assume text messages have a first character in command parsing
Fixes: #271
2021-05-16 02:53:12 +02:00
efcd19eab7 update nodejs lib
#SECURITY
2021-05-15 23:28:21 +02:00
abc8c72c7f adding type debug 2021-05-15 22:45:11 +02:00
3 changed files with 38 additions and 57 deletions

View File

@ -142,7 +142,7 @@ class CachedItemWrapper:
if self.id in self.lib: if self.id in self.lib:
return self.lib[self.id] return self.lib[self.id]
else: else:
raise ValueError(f"Uncached item of id {self.id}.") raise ValueError(f"Uncached item of id {self.id}, type {self.type}.")
def to_dict(self): def to_dict(self):
dict = self.item().to_dict() dict = self.item().to_dict()

View File

@ -252,7 +252,7 @@ class MumbleBot:
# you want to split the username # you want to split the username
user = user.split()[0] user = user.split()[0]
if message[0] in var.config.get('commands', 'command_symbol'): if message.startswith(tuple(var.config.get('commands', 'command_symbol'))):
# remove the symbol from the message # remove the symbol from the message
message = message[1:].split(' ', 1) message = message[1:].split(' ', 1)

91
web/package-lock.json generated
View File

@ -2087,7 +2087,6 @@
"dependencies": { "dependencies": {
"anymatch": "~3.1.1", "anymatch": "~3.1.1",
"braces": "~3.0.2", "braces": "~3.0.2",
"fsevents": "~2.1.2",
"glob-parent": "~5.1.0", "glob-parent": "~5.1.0",
"is-binary-path": "~2.1.0", "is-binary-path": "~2.1.0",
"is-glob": "~4.0.1", "is-glob": "~4.0.1",
@ -2150,9 +2149,9 @@
"dev": true "dev": true
}, },
"node_modules/colorette": { "node_modules/colorette": {
"version": "1.2.1", "version": "1.2.2",
"resolved": "https://registry.npmjs.org/colorette/-/colorette-1.2.1.tgz", "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.2.2.tgz",
"integrity": "sha512-puCDz0CzydiSYOrnXpz/PKd69zRrribezjtE9yd4zvytoRc8+RY/KJPvtPFKZS3E3wP6neGyMe0vOTlHO5L3Pw==", "integrity": "sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==",
"dev": true "dev": true
}, },
"node_modules/command-line-usage": { "node_modules/command-line-usage": {
@ -3481,9 +3480,9 @@
} }
}, },
"node_modules/hosted-git-info": { "node_modules/hosted-git-info": {
"version": "2.8.8", "version": "2.8.9",
"resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.8.tgz", "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz",
"integrity": "sha512-f/wzC2QaWBs7t9IYqB4T3sR1xviIViXJRJTWBlx2Gf3g0Xi5vI7Yy4koXQ1c9OYDGHN9sBy1DQ2AB8fqZBWhUg==", "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==",
"dev": true "dev": true
}, },
"node_modules/html-minifier-terser": { "node_modules/html-minifier-terser": {
@ -4148,9 +4147,9 @@
} }
}, },
"node_modules/lodash": { "node_modules/lodash": {
"version": "4.17.20", "version": "4.17.21",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
"integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
"dev": true "dev": true
}, },
"node_modules/lower-case": { "node_modules/lower-case": {
@ -4301,9 +4300,9 @@
"dev": true "dev": true
}, },
"node_modules/nanoid": { "node_modules/nanoid": {
"version": "3.1.18", "version": "3.1.23",
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.18.tgz", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.23.tgz",
"integrity": "sha512-rndlDjbbHbcV3xi+R2fpJ+PbGMdfBxz5v1fATIQFq0DP64FsicQdwnKLy47K4kZHdRpmQXtz24eGsxQqamzYTA==", "integrity": "sha512-FiB0kzdP0FFVGDKlRLEQ1BgDzU87dy5NnzjeW9YZNt+/c3+q82EQDUwniSAUxp/F0gFNI1ZhKU1FqYsMuqZVnw==",
"dev": true, "dev": true,
"bin": { "bin": {
"nanoid": "bin/nanoid.cjs" "nanoid": "bin/nanoid.cjs"
@ -4727,15 +4726,14 @@
} }
}, },
"node_modules/postcss": { "node_modules/postcss": {
"version": "8.1.10", "version": "8.2.15",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.1.10.tgz", "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.2.15.tgz",
"integrity": "sha512-iBXEV5VTTYaRRdxiFYzTtuv2lGMQBExqkZKSzkJe+Fl6rvQrA/49UVGKqB+LG54hpW/TtDBMGds8j33GFNW7pg==", "integrity": "sha512-2zO3b26eJD/8rb106Qu2o7Qgg52ND5HPjcyQiK2B98O388h43A448LCslC0dI2P97wCAQRJsFvwTRcXxTKds+Q==",
"dev": true, "dev": true,
"dependencies": { "dependencies": {
"colorette": "^1.2.1", "colorette": "^1.2.2",
"nanoid": "^3.1.18", "nanoid": "^3.1.23",
"source-map": "^0.6.1", "source-map": "^0.6.1"
"vfile-location": "^3.2.0"
}, },
"engines": { "engines": {
"node": "^10 || ^12 || >=14" "node": "^10 || ^12 || >=14"
@ -6002,16 +6000,6 @@
"spdx-expression-parse": "^3.0.0" "spdx-expression-parse": "^3.0.0"
} }
}, },
"node_modules/vfile-location": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/vfile-location/-/vfile-location-3.2.0.tgz",
"integrity": "sha512-aLEIZKv/oxuCDZ8lkJGhuhztf/BW4M+iHdCwglA/eWc+vtuRFJj8EtgceYFX4LRjOhCAAiNHsKGssC6onJ+jbA==",
"dev": true,
"funding": {
"type": "opencollective",
"url": "https://opencollective.com/unified"
}
},
"node_modules/watchpack": { "node_modules/watchpack": {
"version": "2.0.1", "version": "2.0.1",
"resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.0.1.tgz", "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.0.1.tgz",
@ -8120,9 +8108,9 @@
"dev": true "dev": true
}, },
"colorette": { "colorette": {
"version": "1.2.1", "version": "1.2.2",
"resolved": "https://registry.npmjs.org/colorette/-/colorette-1.2.1.tgz", "resolved": "https://registry.npmjs.org/colorette/-/colorette-1.2.2.tgz",
"integrity": "sha512-puCDz0CzydiSYOrnXpz/PKd69zRrribezjtE9yd4zvytoRc8+RY/KJPvtPFKZS3E3wP6neGyMe0vOTlHO5L3Pw==", "integrity": "sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==",
"dev": true "dev": true
}, },
"command-line-usage": { "command-line-usage": {
@ -9140,9 +9128,9 @@
"dev": true "dev": true
}, },
"hosted-git-info": { "hosted-git-info": {
"version": "2.8.8", "version": "2.8.9",
"resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.8.tgz", "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-2.8.9.tgz",
"integrity": "sha512-f/wzC2QaWBs7t9IYqB4T3sR1xviIViXJRJTWBlx2Gf3g0Xi5vI7Yy4koXQ1c9OYDGHN9sBy1DQ2AB8fqZBWhUg==", "integrity": "sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==",
"dev": true "dev": true
}, },
"html-minifier-terser": { "html-minifier-terser": {
@ -9639,9 +9627,9 @@
} }
}, },
"lodash": { "lodash": {
"version": "4.17.20", "version": "4.17.21",
"resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.20.tgz", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz",
"integrity": "sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==", "integrity": "sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==",
"dev": true "dev": true
}, },
"lower-case": { "lower-case": {
@ -9756,9 +9744,9 @@
"dev": true "dev": true
}, },
"nanoid": { "nanoid": {
"version": "3.1.18", "version": "3.1.23",
"resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.18.tgz", "resolved": "https://registry.npmjs.org/nanoid/-/nanoid-3.1.23.tgz",
"integrity": "sha512-rndlDjbbHbcV3xi+R2fpJ+PbGMdfBxz5v1fATIQFq0DP64FsicQdwnKLy47K4kZHdRpmQXtz24eGsxQqamzYTA==", "integrity": "sha512-FiB0kzdP0FFVGDKlRLEQ1BgDzU87dy5NnzjeW9YZNt+/c3+q82EQDUwniSAUxp/F0gFNI1ZhKU1FqYsMuqZVnw==",
"dev": true "dev": true
}, },
"natural-compare": { "natural-compare": {
@ -10079,15 +10067,14 @@
"integrity": "sha512-Wb4p1J4zyFTbM+u6WuO4XstYx4Ky9Cewe4DWrel7B0w6VVICvPwdOpotjzcf6eD8TsckVnIMNONQyPIUFOUbCQ==" "integrity": "sha512-Wb4p1J4zyFTbM+u6WuO4XstYx4Ky9Cewe4DWrel7B0w6VVICvPwdOpotjzcf6eD8TsckVnIMNONQyPIUFOUbCQ=="
}, },
"postcss": { "postcss": {
"version": "8.1.10", "version": "8.2.15",
"resolved": "https://registry.npmjs.org/postcss/-/postcss-8.1.10.tgz", "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.2.15.tgz",
"integrity": "sha512-iBXEV5VTTYaRRdxiFYzTtuv2lGMQBExqkZKSzkJe+Fl6rvQrA/49UVGKqB+LG54hpW/TtDBMGds8j33GFNW7pg==", "integrity": "sha512-2zO3b26eJD/8rb106Qu2o7Qgg52ND5HPjcyQiK2B98O388h43A448LCslC0dI2P97wCAQRJsFvwTRcXxTKds+Q==",
"dev": true, "dev": true,
"requires": { "requires": {
"colorette": "^1.2.1", "colorette": "^1.2.2",
"nanoid": "^3.1.18", "nanoid": "^3.1.23",
"source-map": "^0.6.1", "source-map": "^0.6.1"
"vfile-location": "^3.2.0"
}, },
"dependencies": { "dependencies": {
"source-map": { "source-map": {
@ -11037,12 +11024,6 @@
"spdx-expression-parse": "^3.0.0" "spdx-expression-parse": "^3.0.0"
} }
}, },
"vfile-location": {
"version": "3.2.0",
"resolved": "https://registry.npmjs.org/vfile-location/-/vfile-location-3.2.0.tgz",
"integrity": "sha512-aLEIZKv/oxuCDZ8lkJGhuhztf/BW4M+iHdCwglA/eWc+vtuRFJj8EtgceYFX4LRjOhCAAiNHsKGssC6onJ+jbA==",
"dev": true
},
"watchpack": { "watchpack": {
"version": "2.0.1", "version": "2.0.1",
"resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.0.1.tgz", "resolved": "https://registry.npmjs.org/watchpack/-/watchpack-2.0.1.tgz",