mirror of
https://git.joinfirefish.org/firefish/firefish.git
synced 2024-05-18 08:31:09 +02:00
chore (backend): fix imports
This commit is contained in:
parent
dd3ad89b64
commit
a2699e6687
|
@ -1,6 +1,6 @@
|
||||||
import { redisClient } from "@/db/redis.js";
|
import { redisClient } from "@/db/redis.js";
|
||||||
import { encode, decode } from "msgpackr";
|
import { encode, decode } from "msgpackr";
|
||||||
import { ChainableCommander } from "ioredis";
|
import type { ChainableCommander } from "ioredis";
|
||||||
|
|
||||||
export class Cache<T> {
|
export class Cache<T> {
|
||||||
private ttl: number;
|
private ttl: number;
|
||||||
|
|
|
@ -32,7 +32,7 @@ import Followers from "./activitypub/followers.js";
|
||||||
import Outbox, { packActivity } from "./activitypub/outbox.js";
|
import Outbox, { packActivity } from "./activitypub/outbox.js";
|
||||||
import { serverLogger } from "./index.js";
|
import { serverLogger } from "./index.js";
|
||||||
import config from "@/config/index.js";
|
import config from "@/config/index.js";
|
||||||
import Koa from "koa";
|
import type Koa from "koa";
|
||||||
import * as crypto from "node:crypto";
|
import * as crypto from "node:crypto";
|
||||||
import { inspect } from "node:util";
|
import { inspect } from "node:util";
|
||||||
import type { IActivity } from "@/remote/activitypub/type.js";
|
import type { IActivity } from "@/remote/activitypub/type.js";
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { Readable, ReadableOptions } from "node:stream";
|
import { Readable, type ReadableOptions } from "node:stream";
|
||||||
import { Buffer } from "node:buffer";
|
import { Buffer } from "node:buffer";
|
||||||
import * as fs from "node:fs";
|
import * as fs from "node:fs";
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
import type { KVs } from "../core.js";
|
|
||||||
import Chart from "../core.js";
|
import Chart from "../core.js";
|
||||||
import type { User } from "@/models/entities/user.js";
|
import type { User } from "@/models/entities/user.js";
|
||||||
import { name, schema } from "./entities/active-users.js";
|
import { name, schema } from "./entities/active-users.js";
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import { Window } from "happy-dom";
|
import { Window } from "happy-dom";
|
||||||
|
import type { HTMLAnchorElement, HTMLLinkElement } from "happy-dom";
|
||||||
import config from "@/config/index.js";
|
import config from "@/config/index.js";
|
||||||
|
|
||||||
async function getRelMeLinks(url: string): Promise<string[]> {
|
async function getRelMeLinks(url: string): Promise<string[]> {
|
||||||
|
|
|
@ -3,7 +3,6 @@ import type { Note } from "@/models/entities/note.js";
|
||||||
import type { User } from "@/models/entities/user.js";
|
import type { User } from "@/models/entities/user.js";
|
||||||
import {
|
import {
|
||||||
NoteUnreads,
|
NoteUnreads,
|
||||||
Users,
|
|
||||||
Followings,
|
Followings,
|
||||||
ChannelFollowings,
|
ChannelFollowings,
|
||||||
} from "@/models/index.js";
|
} from "@/models/index.js";
|
||||||
|
@ -120,34 +119,4 @@ export default async function (
|
||||||
]),
|
]),
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
// if (readAntennaNotes.length > 0) {
|
|
||||||
// await AntennaNotes.update(
|
|
||||||
// {
|
|
||||||
// antennaId: In(myAntennas.map((a) => a.id)),
|
|
||||||
// noteId: In(readAntennaNotes.map((n) => n.id)),
|
|
||||||
// },
|
|
||||||
// {
|
|
||||||
// read: true,
|
|
||||||
// },
|
|
||||||
// );
|
|
||||||
|
|
||||||
// // TODO: まとめてクエリしたい
|
|
||||||
// for (const antenna of myAntennas) {
|
|
||||||
// const count = await AntennaNotes.countBy({
|
|
||||||
// antennaId: antenna.id,
|
|
||||||
// read: false,
|
|
||||||
// });
|
|
||||||
|
|
||||||
// if (count === 0) {
|
|
||||||
// publishMainStream(userId, "readAntenna", antenna);
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
// Users.getHasUnreadAntenna(userId).then((unread) => {
|
|
||||||
// if (!unread) {
|
|
||||||
// publishMainStream(userId, "readAllAntennas");
|
|
||||||
// }
|
|
||||||
// });
|
|
||||||
// }
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue