Update migrate.ts

This commit is contained in:
syuilo 2019-04-13 15:09:16 +09:00
parent 6af19794b6
commit 14bcb813cc
No known key found for this signature in database
GPG Key ID: BDC4C49D06AB9D69
1 changed files with 6 additions and 1 deletions

View File

@ -24,9 +24,14 @@ import { UserPublickey } from './models/entities/user-publickey';
import { UserKeypair } from './models/entities/user-keypair'; import { UserKeypair } from './models/entities/user-keypair';
import { extractPublic } from './crypto_key'; import { extractPublic } from './crypto_key';
import { Emoji } from './models/entities/emoji'; import { Emoji } from './models/entities/emoji';
import { toPuny } from './misc/convert-host'; import { toPuny as _toPuny } from './misc/convert-host';
import { UserProfile } from './models/entities/user-profile'; import { UserProfile } from './models/entities/user-profile';
function toPuny(x: string | null): string | null {
if (x == null) return null;
return _toPuny(x);
}
const u = (config as any).mongodb.user ? encodeURIComponent((config as any).mongodb.user) : null; const u = (config as any).mongodb.user ? encodeURIComponent((config as any).mongodb.user) : null;
const p = (config as any).mongodb.pass ? encodeURIComponent((config as any).mongodb.pass) : null; const p = (config as any).mongodb.pass ? encodeURIComponent((config as any).mongodb.pass) : null;