[API] お気に入り状態は投稿情報に含めないように統一

This commit is contained in:
syuilo
2019-02-05 01:11:06 +09:00
parent 06707705bf
commit c107333f56
3 changed files with 99 additions and 71 deletions

View File

@ -9,7 +9,6 @@ import { pack as packApp } from './app';
import PollVote from './poll-vote';
import Reaction from './note-reaction';
import { packMany as packFileMany, IDriveFile } from './drive-file';
import Favorite from './favorite';
import Following from './following';
import Emoji from './emoji';
@ -346,19 +345,6 @@ export const pack = async (
return null;
})();
// isFavorited
_note.isFavorited = (async () => {
const favorite = await Favorite
.count({
userId: meId,
noteId: id
}, {
limit: 1
});
return favorite === 1;
})();
}
}