halbot 1995.1.13 → 1995.1.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/lib/hal.mjs CHANGED
@@ -263,7 +263,7 @@ const extendSessionStorage = storage => storage && storage.client && {
263
263
 
264
264
  const subconscious = {
265
265
  name: 'Subconscious', run: true, priority: 0,
266
- func: async (_, next) => ignoreErrFunc(next, logOptions), // non-blocking
266
+ func: async (_, next) => { ignoreErrFunc(next, logOptions) }, // non-blocking
267
267
  };
268
268
 
269
269
  const init = async (options) => {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "halbot",
3
3
  "description": "Just another AI powered Telegram bot, which is simple design, easy to use, extendable and fun.",
4
- "version": "1995.1.13",
4
+ "version": "1995.1.15",
5
5
  "private": false,
6
6
  "homepage": "https://github.com/Leask/halbot",
7
7
  "type": "module",
@@ -62,7 +62,7 @@ const collectFile = async (ctx, f) => {
62
62
 
63
63
  const extract = async (ctx, m) => {
64
64
  collectableObjects.map(k => {
65
- if (k === 'new_chat_member' && m[k].user.id === ctx.botInfo.id) {
65
+ if (k === 'new_chat_member' && m[k]?.user?.id === ctx.botInfo.id) {
66
66
  return; // ignore current bot joining the group
67
67
  }
68
68
  return m[k] && ctx.collect(