This commit is contained in:
syuilo 2018-04-02 04:15:27 +09:00
parent e8bde94e5b
commit cd2542e0fd
99 changed files with 111 additions and 111 deletions

View file

@ -229,7 +229,7 @@
</style> </style>
<script lang="typescript"> <script lang="typescript">
import getAcct from '../../../../common/user/get-acct'; import getAcct from '../../../../misc/user/get-acct';
this.post = this.opts.post; this.post = this.opts.post;
this.form = this.opts.form; this.form = this.opts.form;

View file

@ -1,5 +1,5 @@
import getPostSummary from '../../../../common/get-post-summary'; import getPostSummary from '../../../../misc/get-post-summary';
import getReactionEmoji from '../../../../common/get-reaction-emoji'; import getReactionEmoji from '../../../../misc/get-reaction-emoji';
type Notification = { type Notification = {
title: string; title: string;

View file

@ -21,7 +21,7 @@
import Vue from 'vue'; import Vue from 'vue';
import * as emojilib from 'emojilib'; import * as emojilib from 'emojilib';
import contains from '../../../common/scripts/contains'; import contains from '../../../common/scripts/contains';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
const lib = Object.entries(emojilib.lib).filter((x: any) => { const lib = Object.entries(emojilib.lib).filter((x: any) => {
return x[1].category != 'flags'; return x[1].category != 'flags';

View file

@ -34,7 +34,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import parse from '../../../../../common/text/parse'; import parse from '../../../../../common/text/parse';
export default Vue.extend({ export default Vue.extend({

View file

@ -51,7 +51,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: { props: {

View file

@ -43,7 +43,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import * as CRC32 from 'crc-32'; import * as CRC32 from 'crc-32';
import Othello, { Color } from '../../../../../common/othello/core'; import Othello, { Color } from '../../../../../misc/othello/core';
import { url } from '../../../config'; import { url } from '../../../config';
export default Vue.extend({ export default Vue.extend({

View file

@ -94,7 +94,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import * as maps from '../../../../../common/othello/maps'; import * as maps from '../../../../../misc/othello/maps';
export default Vue.extend({ export default Vue.extend({
props: ['game', 'connection'], props: ['game', 'connection'],

View file

@ -1,7 +1,7 @@
import Vue from 'vue'; import Vue from 'vue';
import * as emojilib from 'emojilib'; import * as emojilib from 'emojilib';
import parse from '../../../../../common/text/parse'; import parse from '../../../../../common/text/parse';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import { url } from '../../../config'; import { url } from '../../../config';
import MkUrl from './url.vue'; import MkUrl from './url.vue';

View file

@ -24,7 +24,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -22,7 +22,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -8,7 +8,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import { url } from '../../../config'; import { url } from '../../../config';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -102,8 +102,8 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import getPostSummary from '../../../../../common/get-post-summary'; import getPostSummary from '../../../../../misc/get-post-summary';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -28,7 +28,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import dateStringify from '../../../common/scripts/date-stringify'; import dateStringify from '../../../common/scripts/date-stringify';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -78,7 +78,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import dateStringify from '../../../common/scripts/date-stringify'; import dateStringify from '../../../common/scripts/date-stringify';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import parse from '../../../../../common/text/parse'; import parse from '../../../../../common/text/parse';
import MkPostFormWindow from './post-form-window.vue'; import MkPostFormWindow from './post-form-window.vue';

View file

@ -21,7 +21,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import dateStringify from '../../../common/scripts/date-stringify'; import dateStringify from '../../../common/scripts/date-stringify';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -21,7 +21,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import dateStringify from '../../../common/scripts/date-stringify'; import dateStringify from '../../../common/scripts/date-stringify';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -85,7 +85,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import dateStringify from '../../../common/scripts/date-stringify'; import dateStringify from '../../../common/scripts/date-stringify';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import parse from '../../../../../common/text/parse'; import parse from '../../../../../common/text/parse';
import MkPostFormWindow from './post-form-window.vue'; import MkPostFormWindow from './post-form-window.vue';

View file

@ -13,7 +13,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -29,8 +29,8 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import * as anime from 'animejs'; import * as anime from 'animejs';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import parseAcct from '../../../../../common/user/parse-acct'; import parseAcct from '../../../../../misc/user/parse-acct';
export default Vue.extend({ export default Vue.extend({
props: { props: {

View file

@ -19,7 +19,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -7,7 +7,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import Progress from '../../../common/scripts/loading'; import Progress from '../../../common/scripts/loading';
import getPostSummary from '../../../../../common/get-post-summary'; import getPostSummary from '../../../../../misc/get-post-summary';
export default Vue.extend({ export default Vue.extend({
props: { props: {

View file

@ -7,7 +7,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import Progress from '../../../common/scripts/loading'; import Progress from '../../../common/scripts/loading';
import parseAcct from '../../../../../common/user/parse-acct'; import parseAcct from '../../../../../misc/user/parse-acct';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -13,7 +13,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../../common/user/get-acct'; import getAcct from '../../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -20,7 +20,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../../common/user/get-acct'; import getAcct from '../../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -22,7 +22,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../../common/user/get-acct'; import getAcct from '../../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -9,7 +9,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import parseAcct from '../../../../../../common/user/parse-acct'; import parseAcct from '../../../../../../misc/user/parse-acct';
import Progress from '../../../../common/scripts/loading'; import Progress from '../../../../common/scripts/loading';
import XHeader from './user.header.vue'; import XHeader from './user.header.vue';
import XHome from './user.home.vue'; import XHome from './user.home.vue';

View file

@ -43,7 +43,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import { docsUrl, copyright, lang } from '../../../config'; import { docsUrl, copyright, lang } from '../../../config';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
const shares = [ const shares = [
'Everything!', 'Everything!',

View file

@ -19,7 +19,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -16,7 +16,7 @@
<script lang="ts"> <script lang="ts">
import define from '../../../common/define-widget'; import define from '../../../common/define-widget';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default define({ export default define({
name: 'polls', name: 'polls',

View file

@ -15,7 +15,7 @@
<script lang="ts"> <script lang="ts">
import define from '../../../common/define-widget'; import define from '../../../common/define-widget';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default define({ export default define({
name: 'trends', name: 'trends',

View file

@ -23,7 +23,7 @@
<script lang="ts"> <script lang="ts">
import define from '../../../common/define-widget'; import define from '../../../common/define-widget';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
const limit = 3; const limit = 3;

View file

@ -1,6 +1,6 @@
import PostForm from '../views/components/post-form.vue'; import PostForm from '../views/components/post-form.vue';
//import RepostForm from '../views/components/repost-form.vue'; //import RepostForm from '../views/components/repost-form.vue';
import getPostSummary from '../../../../common/get-post-summary'; import getPostSummary from '../../../../misc/get-post-summary';
export default (os) => (opts) => { export default (os) => (opts) => {
const o = opts || {}; const o = opts || {};

View file

@ -59,7 +59,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getPostSummary from '../../../../../common/get-post-summary'; import getPostSummary from '../../../../../misc/get-post-summary';
export default Vue.extend({ export default Vue.extend({
props: ['notification'], props: ['notification'],

View file

@ -78,8 +78,8 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getPostSummary from '../../../../../common/get-post-summary'; import getPostSummary from '../../../../../misc/get-post-summary';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['notification'], props: ['notification'],

View file

@ -14,8 +14,8 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import summary from '../../../../../common/get-post-summary'; import summary from '../../../../../misc/get-post-summary';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -20,7 +20,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -80,7 +80,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import parse from '../../../../../common/text/parse'; import parse from '../../../../../common/text/parse';
import MkPostMenu from '../../../common/views/components/post-menu.vue'; import MkPostMenu from '../../../common/views/components/post-menu.vue';

View file

@ -20,7 +20,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -20,7 +20,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['post'], props: ['post'],

View file

@ -77,7 +77,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import parse from '../../../../../common/text/parse'; import parse from '../../../../../common/text/parse';
import MkPostMenu from '../../../common/views/components/post-menu.vue'; import MkPostMenu from '../../../common/views/components/post-menu.vue';

View file

@ -13,7 +13,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -17,7 +17,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -19,7 +19,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import Progress from '../../../common/scripts/loading'; import Progress from '../../../common/scripts/loading';
import parseAcct from '../../../../../common/user/parse-acct'; import parseAcct from '../../../../../misc/user/parse-acct';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -19,7 +19,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import Progress from '../../../common/scripts/loading'; import Progress from '../../../common/scripts/loading';
import parseAcct from '../../../../../common/user/parse-acct'; import parseAcct from '../../../../../misc/user/parse-acct';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -64,7 +64,7 @@ import Vue from 'vue';
import * as XDraggable from 'vuedraggable'; import * as XDraggable from 'vuedraggable';
import * as uuid from 'uuid'; import * as uuid from 'uuid';
import Progress from '../../../common/scripts/loading'; import Progress from '../../../common/scripts/loading';
import getPostSummary from '../../../../../common/get-post-summary'; import getPostSummary from '../../../../../misc/get-post-summary';
export default Vue.extend({ export default Vue.extend({
components: { components: {

View file

@ -10,7 +10,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import parseAcct from '../../../../../common/user/parse-acct'; import parseAcct from '../../../../../misc/user/parse-acct';
export default Vue.extend({ export default Vue.extend({
data() { data() {

View file

@ -7,7 +7,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
mounted() { mounted() {

View file

@ -60,8 +60,8 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import * as age from 's-age'; import * as age from 's-age';
import getAcct from '../../../../../common/user/get-acct'; import getAcct from '../../../../../misc/user/get-acct';
import getAcct from '../../../../../common/user/parse-acct'; import getAcct from '../../../../../misc/user/parse-acct';
import Progress from '../../../common/scripts/loading'; import Progress from '../../../common/scripts/loading';
import XHome from './user/home.vue'; import XHome from './user/home.vue';

View file

@ -12,7 +12,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../../common/user/get-acct'; import getAcct from '../../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -14,7 +14,7 @@
<script lang="ts"> <script lang="ts">
import Vue from 'vue'; import Vue from 'vue';
import getAcct from '../../../../../../common/user/get-acct'; import getAcct from '../../../../../../misc/user/get-acct';
export default Vue.extend({ export default Vue.extend({
props: ['user'], props: ['user'],

View file

@ -14,7 +14,7 @@ import DriveFile, { getGridFSBucket } from '../../models/drive-file';
import DriveFolder from '../../models/drive-folder'; import DriveFolder from '../../models/drive-folder';
import { pack } from '../../models/drive-file'; import { pack } from '../../models/drive-file';
import event, { publishDriveStream } from '../event'; import event, { publishDriveStream } from '../event';
import getAcct from '../user/get-acct'; import getAcct from '../../misc/user/get-acct';
import config from '../../conf'; import config from '../../conf';
const gm = _gm.subClass({ const gm = _gm.subClass({

View file

@ -1,7 +1,7 @@
/** /**
* Mention * Mention
*/ */
import parseAcct from '../../../../common/user/parse-acct'; import parseAcct from '../../../../misc/user/parse-acct';
module.exports = text => { module.exports = text => {
const match = text.match(/^(?:@[a-zA-Z0-9\-]+){1,2}/); const match = text.match(/^(?:@[a-zA-Z0-9\-]+){1,2}/);

View file

@ -5,8 +5,8 @@ import User, { isLocalUser, pack as packUser, ILocalUser } from '../../models/us
import Following from '../../models/following'; import Following from '../../models/following';
import event from '../../common/event'; import event from '../../common/event';
import notify from '../../common/notify'; import notify from '../../common/notify';
import context from '../../common/remote/activitypub/renderer/context'; import context from '../../remote/activitypub/renderer/context';
import render from '../../common/remote/activitypub/renderer/follow'; import render from '../../remote/activitypub/renderer/follow';
import config from '../../conf'; import config from '../../conf';
export default ({ data }, done) => Following.findOne({ _id: data.following }).then(({ followerId, followeeId }) => { export default ({ data }, done) => Following.findOne({ _id: data.following }).then(({ followerId, followeeId }) => {

View file

@ -1,5 +1,5 @@
import User from '../../models/user'; import User from '../../models/user';
import act from '../../common/remote/activitypub/act'; import act from '../../remote/activitypub/act';
export default ({ data }, done) => User.findOne({ _id: data.actor }) export default ({ data }, done) => User.findOne({ _id: data.actor })
.then(actor => act(actor, data.outbox)) .then(actor => act(actor, data.outbox))

View file

@ -1,8 +1,8 @@
import { JSDOM } from 'jsdom'; import { JSDOM } from 'jsdom';
import config from '../../../conf'; import config from '../../conf';
import Post from '../../../models/post'; import Post from '../../models/post';
import RemoteUserObject, { IRemoteUserObject } from '../../../models/remote-user-object'; import RemoteUserObject, { IRemoteUserObject } from '../../models/remote-user-object';
import uploadFromUrl from '../../drive/upload_from_url'; import uploadFromUrl from '../../common/drive/upload-from-url';
import Resolver from './resolver'; import Resolver from './resolver';
const createDOMPurify = require('dompurify'); const createDOMPurify = require('dompurify');

View file

@ -1,4 +1,4 @@
import config from '../../../../conf'; import config from '../../../conf';
export default ({ _id, contentType }) => ({ export default ({ _id, contentType }) => ({
type: 'Document', type: 'Document',

View file

@ -1,5 +1,5 @@
import config from '../../../../conf'; import config from '../../../conf';
import { IRemoteUser } from '../../../../models/user'; import { IRemoteUser } from '../../../models/user';
export default ({ username }, followee: IRemoteUser) => ({ export default ({ username }, followee: IRemoteUser) => ({
type: 'Follow', type: 'Follow',

View file

@ -1,4 +1,4 @@
import config from '../../../../conf'; import config from '../../../conf';
export default tag => ({ export default tag => ({
type: 'Hashtag', type: 'Hashtag',

View file

@ -1,4 +1,4 @@
import config from '../../../../conf'; import config from '../../../conf';
export default ({ _id }) => ({ export default ({ _id }) => ({
type: 'Image', type: 'Image',

View file

@ -1,6 +1,6 @@
import config from '../../../../conf'; import config from '../../../conf';
import { extractPublic } from '../../../../crypto_key'; import { extractPublic } from '../../../crypto_key';
import { ILocalUser } from '../../../../models/user'; import { ILocalUser } from '../../../models/user';
export default (user: ILocalUser) => ({ export default (user: ILocalUser) => ({
id: `${config.url}/@${user.username}/publickey`, id: `${config.url}/@${user.username}/publickey`,

View file

@ -1,9 +1,9 @@
import renderDocument from './document'; import renderDocument from './document';
import renderHashtag from './hashtag'; import renderHashtag from './hashtag';
import config from '../../../../conf'; import config from '../../../conf';
import DriveFile from '../../../../models/drive-file'; import DriveFile from '../../../models/drive-file';
import Post from '../../../../models/post'; import Post from '../../../models/post';
import User from '../../../../models/user'; import User from '../../../models/user';
export default async (user, post) => { export default async (user, post) => {
const promisedFiles = DriveFile.find({ _id: { $in: post.mediaIds } }); const promisedFiles = DriveFile.find({ _id: { $in: post.mediaIds } });

View file

@ -1,6 +1,6 @@
import renderImage from './image'; import renderImage from './image';
import renderKey from './key'; import renderKey from './key';
import config from '../../../../conf'; import config from '../../../conf';
export default user => { export default user => {
const id = `${config.url}/@${user.username}`; const id = `${config.url}/@${user.username}`;

View file

@ -1,7 +1,7 @@
import { JSDOM } from 'jsdom'; import { JSDOM } from 'jsdom';
import { toUnicode } from 'punycode'; import { toUnicode } from 'punycode';
import User, { validateUsername, isValidName, isValidDescription } from '../../../models/user'; import User, { validateUsername, isValidName, isValidDescription } from '../../models/user';
import queue from '../../../queue'; import queue from '../../queue';
import webFinger from '../webfinger'; import webFinger from '../webfinger';
import create from './create'; import create from './create';
import Resolver from './resolver'; import Resolver from './resolver';

View file

@ -1,4 +1,4 @@
import RemoteUserObject from '../../../models/remote-user-object'; import RemoteUserObject from '../../models/remote-user-object';
import { IObject } from './type'; import { IObject } from './type';
const request = require('request-promise-native'); const request = require('request-promise-native');

View file

@ -1,5 +1,5 @@
import { toUnicode, toASCII } from 'punycode'; import { toUnicode, toASCII } from 'punycode';
import User from '../../models/user'; import User from '../models/user';
import resolvePerson from './activitypub/resolve-person'; import resolvePerson from './activitypub/resolve-person';
import webFinger from './webfinger'; import webFinger from './webfinger';

View file

@ -3,7 +3,7 @@ import * as express from 'express';
import { parseRequest, verifySignature } from 'http-signature'; import { parseRequest, verifySignature } from 'http-signature';
import User, { IRemoteUser } from '../../models/user'; import User, { IRemoteUser } from '../../models/user';
import queue from '../../queue'; import queue from '../../queue';
import parseAcct from '../../common/user/parse-acct'; import parseAcct from '../../misc/user/parse-acct';
const app = express(); const app = express();
app.disable('x-powered-by'); app.disable('x-powered-by');

View file

@ -1,7 +1,7 @@
import * as express from 'express'; import * as express from 'express';
import context from '../../common/remote/activitypub/renderer/context'; import context from '../../remote/activitypub/renderer/context';
import renderNote from '../../common/remote/activitypub/renderer/note'; import renderNote from '../../remote/activitypub/renderer/note';
import renderOrderedCollection from '../../common/remote/activitypub/renderer/ordered-collection'; import renderOrderedCollection from '../../remote/activitypub/renderer/ordered-collection';
import config from '../../conf'; import config from '../../conf';
import Post from '../../models/post'; import Post from '../../models/post';
import withUser from './with-user'; import withUser from './with-user';

View file

@ -1,7 +1,7 @@
import * as express from 'express'; import * as express from 'express';
import context from '../../common/remote/activitypub/renderer/context'; import context from '../../remote/activitypub/renderer/context';
import render from '../../common/remote/activitypub/renderer/note'; import render from '../../remote/activitypub/renderer/note';
import parseAcct from '../../common/user/parse-acct'; import parseAcct from '../../misc/user/parse-acct';
import Post from '../../models/post'; import Post from '../../models/post';
import User from '../../models/user'; import User from '../../models/user';

View file

@ -1,6 +1,6 @@
import * as express from 'express'; import * as express from 'express';
import context from '../../common/remote/activitypub/renderer/context'; import context from '../../remote/activitypub/renderer/context';
import render from '../../common/remote/activitypub/renderer/key'; import render from '../../remote/activitypub/renderer/key';
import config from '../../conf'; import config from '../../conf';
import withUser from './with-user'; import withUser from './with-user';

View file

@ -1,7 +1,7 @@
import * as express from 'express'; import * as express from 'express';
import config from '../../conf'; import config from '../../conf';
import context from '../../common/remote/activitypub/renderer/context'; import context from '../../remote/activitypub/renderer/context';
import render from '../../common/remote/activitypub/renderer/person'; import render from '../../remote/activitypub/renderer/person';
import withUser from './with-user'; import withUser from './with-user';
const respond = withUser(username => `${config.url}/@${username}`, (user, req, res) => { const respond = withUser(username => `${config.url}/@${username}`, (user, req, res) => {

View file

@ -1,4 +1,4 @@
import parseAcct from '../../common/user/parse-acct'; import parseAcct from '../../misc/user/parse-acct';
import User from '../../models/user'; import User from '../../models/user';
export default (redirect, respond) => async (req, res, next) => { export default (redirect, respond) => async (req, res, next) => {

View file

@ -3,10 +3,10 @@ import * as bcrypt from 'bcryptjs';
import User, { IUser, init as initUser, ILocalUser } from '../../../models/user'; import User, { IUser, init as initUser, ILocalUser } from '../../../models/user';
import getPostSummary from '../../../common/get-post-summary'; import getPostSummary from '../../../misc/get-post-summary';
import getUserSummary from '../../../common/user/get-summary'; import getUserSummary from '../../../misc/user/get-summary';
import parseAcct from '../../../common/user/parse-acct'; import parseAcct from '../../../misc/user/parse-acct';
import getNotificationSummary from '../../../common/get-notification-summary'; import getNotificationSummary from '../../../misc/get-notification-summary';
const hmm = [ const hmm = [
'', '',

View file

@ -7,9 +7,9 @@ import config from '../../../../conf';
import BotCore from '../core'; import BotCore from '../core';
import _redis from '../../../../db/redis'; import _redis from '../../../../db/redis';
import prominence = require('prominence'); import prominence = require('prominence');
import getAcct from '../../../../common/user/get-acct'; import getAcct from '../../../../misc/user/get-acct';
import parseAcct from '../../../../common/user/parse-acct'; import parseAcct from '../../../../misc/user/parse-acct';
import getPostSummary from '../../../../common/get-post-summary'; import getPostSummary from '../../../../misc/get-post-summary';
const redis = prominence(_redis); const redis = prominence(_redis);

View file

@ -3,7 +3,7 @@
*/ */
import $ from 'cafy'; import $ from 'cafy';
import { pack } from '../../../../../models/drive-file'; import { pack } from '../../../../../models/drive-file';
import uploadFromUrl from '../../../../../common/drive/upload_from_url'; import uploadFromUrl from '../../../../../common/drive/upload-from-url';
/** /**
* Create a file from a URL * Create a file from a URL

View file

@ -1,6 +1,6 @@
import $ from 'cafy'; import $ from 'cafy';
import OthelloGame, { pack } from '../../../../../models/othello-game'; import OthelloGame, { pack } from '../../../../../models/othello-game';
import Othello from '../../../../../common/othello/core'; import Othello from '../../../../../misc/othello/core';
module.exports = (params, user) => new Promise(async (res, rej) => { module.exports = (params, user) => new Promise(async (res, rej) => {
// Get 'gameId' parameter // Get 'gameId' parameter

View file

@ -3,7 +3,7 @@ import Matching, { pack as packMatching } from '../../../../models/othello-match
import OthelloGame, { pack as packGame } from '../../../../models/othello-game'; import OthelloGame, { pack as packGame } from '../../../../models/othello-game';
import User from '../../../../models/user'; import User from '../../../../models/user';
import publishUserStream, { publishOthelloStream } from '../../../../common/event'; import publishUserStream, { publishOthelloStream } from '../../../../common/event';
import { eighteight } from '../../../../common/othello/maps'; import { eighteight } from '../../../../misc/othello/maps';
module.exports = (params, user) => new Promise(async (res, rej) => { module.exports = (params, user) => new Promise(async (res, rej) => {
// Get 'userId' parameter // Get 'userId' parameter

View file

@ -17,8 +17,8 @@ import { pack } from '../../../../models/post';
import watch from '../../common/watch-post'; import watch from '../../common/watch-post';
import event, { pushSw, publishChannelStream } from '../../../../common/event'; import event, { pushSw, publishChannelStream } from '../../../../common/event';
import notify from '../../../../common/notify'; import notify from '../../../../common/notify';
import getAcct from '../../../../common/user/get-acct'; import getAcct from '../../../../misc/user/get-acct';
import parseAcct from '../../../../common/user/parse-acct'; import parseAcct from '../../../../misc/user/parse-acct';
import config from '../../../../conf'; import config from '../../../../conf';
/** /**

View file

@ -3,7 +3,7 @@
*/ */
import $ from 'cafy'; import $ from 'cafy';
import User, { pack } from '../../../../models/user'; import User, { pack } from '../../../../models/user';
import resolveRemoteUser from '../../../../common/remote/resolve-user'; import resolveRemoteUser from '../../../../remote/resolve-user';
const cursorOption = { fields: { data: false } }; const cursorOption = { fields: { data: false } };

View file

@ -3,7 +3,7 @@ import * as debug from 'debug';
import limiterDB from '../../db/redis'; import limiterDB from '../../db/redis';
import { Endpoint } from './endpoints'; import { Endpoint } from './endpoints';
import { IAuthContext } from './authenticate'; import { IAuthContext } from './authenticate';
import getAcct from '../../common/user/get-acct'; import getAcct from '../../misc/user/get-acct';
const log = debug('misskey:limitter'); const log = debug('misskey:limitter');

View file

@ -3,8 +3,8 @@ import * as redis from 'redis';
import * as CRC32 from 'crc-32'; import * as CRC32 from 'crc-32';
import OthelloGame, { pack } from '../../../models/othello-game'; import OthelloGame, { pack } from '../../../models/othello-game';
import { publishOthelloGameStream } from '../../../common/event'; import { publishOthelloGameStream } from '../../../common/event';
import Othello from '../../../common/othello/core'; import Othello from '../../../misc/othello/core';
import * as maps from '../../../common/othello/maps'; import * as maps from '../../../misc/othello/maps';
import { ParsedUrlQuery } from 'querystring'; import { ParsedUrlQuery } from 'querystring';
export default function(request: websocket.request, connection: websocket.connection, subscriber: redis.RedisClient, user?: any): void { export default function(request: websocket.request, connection: websocket.connection, subscriber: redis.RedisClient, user?: any): void {

View file

@ -1,5 +1,5 @@
import config from '../conf'; import config from '../conf';
import parseAcct from '../common/user/parse-acct'; import parseAcct from '../misc/user/parse-acct';
import User from '../models/user'; import User from '../models/user';
const express = require('express'); const express = require('express');