forked from FoundKeyGang/FoundKey
wip
This commit is contained in:
parent
070cd52c21
commit
1a13c7e0b1
8 changed files with 11 additions and 10 deletions
|
@ -88,7 +88,7 @@
|
|||
"autwh": "0.1.0",
|
||||
"bcryptjs": "2.4.3",
|
||||
"bootstrap-vue": "2.0.0-rc.6",
|
||||
"cafy": "5.1.0",
|
||||
"cafy": "6.0.0",
|
||||
"chai": "4.1.2",
|
||||
"chai-http": "4.0.0",
|
||||
"chalk": "2.4.0",
|
||||
|
|
|
@ -19,7 +19,7 @@ export default class ID extends Query<mongo.ObjectID> {
|
|||
}
|
||||
};
|
||||
|
||||
this.pushFirstTimeValidator(v => {
|
||||
this.pushValidator(v => {
|
||||
if (!mongo.ObjectID.prototype.isPrototypeOf(v) && isNotAnId(v)) {
|
||||
return new Error('must-be-an-id');
|
||||
}
|
||||
|
|
|
@ -17,7 +17,7 @@
|
|||
<router-link to="/i/favorites">%fa:star%<span>%i18n:@favorites%</span>%fa:angle-right%</router-link>
|
||||
</li>
|
||||
<li @click="list">
|
||||
<p>%fa:cog%<span>%i18n:@lists%</span>%fa:angle-right%</p>
|
||||
<p>%fa:list%<span>%i18n:@lists%</span>%fa:angle-right%</p>
|
||||
</li>
|
||||
</ul>
|
||||
<ul>
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
import * as mongo from 'mongodb';
|
||||
import deepcopy = require('deepcopy');
|
||||
import sequential = require('promise-sequential');
|
||||
import rap from '@prezzemolo/rap';
|
||||
import db from '../db/mongodb';
|
||||
import Note, { pack as packNote, deleteNote } from './note';
|
||||
|
@ -167,9 +168,9 @@ export async function deleteUser(user: string | mongo.ObjectID | IUser) {
|
|||
).map(x => deleteAccessToken(x)));
|
||||
|
||||
// このユーザーのNoteをすべて削除
|
||||
await Promise.all((
|
||||
await Note.find({ userId: u._id })
|
||||
).map(x => deleteNote(x)));
|
||||
//await sequential((
|
||||
// await Note.find({ userId: u._id })
|
||||
//).map(x => () => deleteNote(x)));
|
||||
|
||||
// このユーザーのNoteReactionをすべて削除
|
||||
await Promise.all((
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
*/
|
||||
import rndstr from 'rndstr';
|
||||
const crypto = require('crypto');
|
||||
import $ from 'cafy'; import ID from '../../../../cafy-id';
|
||||
import $ from 'cafy';
|
||||
import App from '../../../../models/app';
|
||||
import AuthSess from '../../../../models/auth-session';
|
||||
import AccessToken from '../../../../models/access-token';
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Module dependencies
|
||||
*/
|
||||
const ms = require('ms');
|
||||
import $ from 'cafy'; import ID from '../../../../cafy-id';
|
||||
import $ from 'cafy';
|
||||
import Note, { pack } from '../../../../models/note';
|
||||
|
||||
/**
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Module dependencies
|
||||
*/
|
||||
const ms = require('ms');
|
||||
import $ from 'cafy'; import ID from '../../../../cafy-id';
|
||||
import $ from 'cafy';
|
||||
import User, { pack } from '../../../../models/user';
|
||||
import { getFriendIds } from '../../common/get-friends';
|
||||
import Mute from '../../../../models/mute';
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
* Module dependencies
|
||||
*/
|
||||
import * as mongo from 'mongodb';
|
||||
import $ from 'cafy'; import ID from '../../../../cafy-id';
|
||||
import $ from 'cafy';
|
||||
import User, { pack } from '../../../../models/user';
|
||||
import config from '../../../../config';
|
||||
const escapeRegexp = require('escape-regexp');
|
||||
|
|
Loading…
Reference in a new issue