Skip to content

Commit

Permalink
fix: 可能修复了表情和 at
Browse files Browse the repository at this point in the history
  • Loading branch information
clansty committed Jul 24, 2024
1 parent 247b43f commit a5e6fef
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ RUN --mount=type=cache,target=/var/cache/apt,sharing=locked \

ADD https://github.com/p-ranav/argparse.git#v3.0 /argparse
WORKDIR /argparse/build
RUN cmake -DARGPARSE_BUILD_SAMPLES=on -DARGPARSE_BUILD_TESTS=on .. && make && make install
RUN cmake -DARGPARSE_BUILD_SAMPLES=off -DARGPARSE_BUILD_TESTS=off .. && make && make install

ADD https://github.com/ed-asriyan/lottie-converter.git#f626548ced4492235b535552e2449be004a3a435 /app
WORKDIR /app
Expand Down
12 changes: 10 additions & 2 deletions main/src/services/ForwardService.ts
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ export default class ForwardService {
break;
}
case 'sface': {
if (!elem.text) {
if (typeof elem.text === 'string') {
elem.text = '表情:' + elem.id;
}
message += `[<i>${helper.htmlEscape(elem.text)}</i>]`;
Expand Down Expand Up @@ -520,9 +520,17 @@ export default class ForwardService {
this.log.error('从 QQ 到 TG 的消息转发失败', e);
posthog.capture('从 QQ 到 TG 的消息转发失败', { error: e });
let pbUrl: string;
let error = e;
if (JSON.stringify(error) === '{}') {
error = {
message: e.message,
stack: e.stack,
str: e.toString(),
};
}
try {
pbUrl = await pastebin.upload(JSON.stringify({
error: e,
error,
event,
}));
}
Expand Down

0 comments on commit a5e6fef

Please sign in to comment.