mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2024-11-21 09:36:35 +00:00
fix: type
This commit is contained in:
parent
f31b0d0c71
commit
2dd0907565
@ -1,7 +1,5 @@
|
|||||||
import crypto from 'node:crypto';
|
|
||||||
import path from 'node:path';
|
import path from 'node:path';
|
||||||
import fs from 'fs';
|
import fs from 'fs';
|
||||||
import * as fsPromise from 'node:fs/promises';
|
|
||||||
import os from 'node:os';
|
import os from 'node:os';
|
||||||
import { QQLevel } from '@/core';
|
import { QQLevel } from '@/core';
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@ import log4js, { Configuration } from 'log4js';
|
|||||||
import { truncateString } from '@/common/utils/helper';
|
import { truncateString } from '@/common/utils/helper';
|
||||||
import path from 'node:path';
|
import path from 'node:path';
|
||||||
import chalk from 'chalk';
|
import chalk from 'chalk';
|
||||||
import { AtType, ChatType, ElementType, ElementWrapper, RawMessage, SelfInfo } from '@/core';
|
import { AtType, ChatType, ElementType, ElementWrapper, MessageElement, RawMessage, SelfInfo } from '@/core';
|
||||||
|
|
||||||
export enum LogLevel {
|
export enum LogLevel {
|
||||||
DEBUG = 'debug',
|
DEBUG = 'debug',
|
||||||
@ -164,7 +164,7 @@ export function rawMessageToText(msg: RawMessage, recursiveLevel = 0): string {
|
|||||||
|
|
||||||
// message content
|
// message content
|
||||||
|
|
||||||
function msgElementToText(element: ElementWrapper) {
|
function msgElementToText(element: MessageElement) {
|
||||||
if (element.textElement) {
|
if (element.textElement) {
|
||||||
if (element.textElement.atType === AtType.notAt) {
|
if (element.textElement.atType === AtType.notAt) {
|
||||||
return element.textElement.content;
|
return element.textElement.content;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user