Merge branch 'stable' into merge-stable-into-develop

This commit is contained in:
Julia Johannesen 2025-04-27 16:19:44 -04:00
commit ac905118cc
No known key found for this signature in database
GPG key ID: 4A1377AF3E7FBC46
19 changed files with 121 additions and 147 deletions

View file

@ -4,8 +4,8 @@
*/
import { Inject, Injectable } from '@nestjs/common';
import { summaly } from '@misskey-dev/summaly';
import { SummalyResult } from '@misskey-dev/summaly/built/summary.js';
import { summaly } from '@transfem-org/summaly';
import { SummalyResult } from '@transfem-org/summaly/built/summary.js';
import * as Redis from 'ioredis';
import { DI } from '@/di-symbols.js';
import type { Config } from '@/config.js';
@ -54,12 +54,10 @@ export class UrlPreviewService {
@bindThis
private wrap(url?: string | null): string | null {
return url != null
? url.match(/^https?:\/\//)
? `${this.config.mediaProxy}/preview.webp?${query({
url,
preview: '1',
})}`
: url
? `${this.config.mediaProxy}/preview.webp?${query({
url,
preview: '1',
})}`
: null;
}