cleanup: trim trailing whitespace (#11136)
* cleanup: trim trailing whitespace * update(`.editorconfig`) --------- Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
This commit is contained in:
@@ -38,9 +38,9 @@ export class FeedService {
|
||||
link: `${this.config.url}/@${user.username}`,
|
||||
name: user.name ?? user.username,
|
||||
};
|
||||
|
||||
|
||||
const profile = await this.userProfilesRepository.findOneByOrFail({ userId: user.id });
|
||||
|
||||
|
||||
const notes = await this.notesRepository.find({
|
||||
where: {
|
||||
userId: user.id,
|
||||
@@ -50,7 +50,7 @@ export class FeedService {
|
||||
order: { createdAt: -1 },
|
||||
take: 20,
|
||||
});
|
||||
|
||||
|
||||
const feed = new Feed({
|
||||
id: author.link,
|
||||
title: `${author.name} (@${user.username}@${this.config.host})`,
|
||||
@@ -66,13 +66,13 @@ export class FeedService {
|
||||
author,
|
||||
copyright: user.name ?? user.username,
|
||||
});
|
||||
|
||||
|
||||
for (const note of notes) {
|
||||
const files = note.fileIds.length > 0 ? await this.driveFilesRepository.findBy({
|
||||
id: In(note.fileIds),
|
||||
}) : [];
|
||||
const file = files.find(file => file.type.startsWith('image/'));
|
||||
|
||||
|
||||
feed.addItem({
|
||||
title: `New note by ${author.name}`,
|
||||
link: `${this.config.url}/notes/${note.id}`,
|
||||
@@ -82,7 +82,7 @@ export class FeedService {
|
||||
image: file ? this.driveFileEntityService.getPublicUrl(file) ?? undefined : undefined,
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
return feed;
|
||||
}
|
||||
}
|
||||
|
@@ -8,7 +8,7 @@ window.onload = async () => {
|
||||
const promise = new Promise((resolve, reject) => {
|
||||
// Append a credential
|
||||
if (i) data.i = i;
|
||||
|
||||
|
||||
// Send request
|
||||
window.fetch(endpoint.indexOf('://') > -1 ? endpoint : `/api/${endpoint}`, {
|
||||
method: 'POST',
|
||||
@@ -17,7 +17,7 @@ window.onload = async () => {
|
||||
cache: 'no-cache'
|
||||
}).then(async (res) => {
|
||||
const body = res.status === 204 ? null : await res.json();
|
||||
|
||||
|
||||
if (res.status === 200) {
|
||||
resolve(body);
|
||||
} else if (res.status === 204) {
|
||||
@@ -27,7 +27,7 @@ window.onload = async () => {
|
||||
}
|
||||
}).catch(reject);
|
||||
});
|
||||
|
||||
|
||||
return promise;
|
||||
};
|
||||
|
||||
|
@@ -8,7 +8,7 @@ window.onload = async () => {
|
||||
const promise = new Promise((resolve, reject) => {
|
||||
// Append a credential
|
||||
if (i) data.i = i;
|
||||
|
||||
|
||||
// Send request
|
||||
fetch(endpoint.indexOf('://') > -1 ? endpoint : `/api/${endpoint}`, {
|
||||
headers: {
|
||||
@@ -20,7 +20,7 @@ window.onload = async () => {
|
||||
cache: 'no-cache'
|
||||
}).then(async (res) => {
|
||||
const body = res.status === 204 ? null : await res.json();
|
||||
|
||||
|
||||
if (res.status === 200) {
|
||||
resolve(body);
|
||||
} else if (res.status === 204) {
|
||||
@@ -30,7 +30,7 @@ window.onload = async () => {
|
||||
}
|
||||
}).catch(reject);
|
||||
});
|
||||
|
||||
|
||||
return promise;
|
||||
};
|
||||
|
||||
|
@@ -55,8 +55,8 @@ html
|
||||
block meta
|
||||
|
||||
block og
|
||||
meta(property='og:title' content= title || 'Misskey')
|
||||
meta(property='og:description' content= desc || '✨🌎✨ A interplanetary communication platform ✨🚀✨')
|
||||
meta(property='og:title' content= title || 'Misskey')
|
||||
meta(property='og:description' content= desc || '✨🌎✨ A interplanetary communication platform ✨🚀✨')
|
||||
meta(property='og:image' content= img)
|
||||
meta(property='twitter:card' content='summary')
|
||||
|
||||
|
@@ -32,12 +32,12 @@ body
|
||||
path(stroke="none", d="M0 0h24v24H0z", fill="none")
|
||||
path(d="M12 9v2m0 4v.01")
|
||||
path(d="M5 19h14a2 2 0 0 0 1.84 -2.75l-7.1 -12.25a2 2 0 0 0 -3.5 0l-7.1 12.25a2 2 0 0 0 1.75 2.75")
|
||||
|
||||
|
||||
h1 An error has occurred!
|
||||
|
||||
button.button-big(onclick="location.reload();")
|
||||
span.button-label-big Refresh
|
||||
|
||||
|
||||
p.dont-worry Don't worry, it's (probably) not your fault.
|
||||
|
||||
p If reloading after a period of time does not resolve the problem, contact the server administrator with the following ERROR ID.
|
||||
|
@@ -43,7 +43,7 @@ block meta
|
||||
meta(name='misskey:user-username' content=user.username)
|
||||
meta(name='misskey:user-id' content=user.id)
|
||||
meta(name='misskey:note-id' content=note.id)
|
||||
|
||||
|
||||
// todo
|
||||
if user.twitter
|
||||
meta(name='twitter:creator' content=`@${user.twitter.screenName}`)
|
||||
|
Reference in New Issue
Block a user