1
0
mirror of https://github.com/misskey-dev/misskey synced 2024-12-01 16:28:33 +09:00

Merge pull request #2482 from syuilo/develop

8.13.0
This commit is contained in:
syuilo 2018-08-25 19:46:50 +09:00 committed by GitHub
commit 2488d40421
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 12 additions and 11 deletions

View File

@ -1,8 +1,8 @@
{
"name": "misskey",
"author": "syuilo <i@syuilo.com>",
"version": "8.12.0",
"clientVersion": "1.0.8981",
"version": "8.13.0",
"clientVersion": "1.0.9001",
"codename": "nighthike",
"main": "./built/index.js",
"private": true,
@ -194,7 +194,7 @@
"stylus": "0.54.5",
"stylus-loader": "3.0.2",
"summaly": "2.1.4",
"systeminformation": "3.42.9",
"systeminformation": "3.43.0",
"syuilo-password-strength": "0.0.1",
"textarea-caret": "3.1.0",
"tmp": "0.0.33",

View File

@ -51,8 +51,9 @@
}
}
if (settings) {
if (settings.device.lang) lang = settings.device.lang;
if (settings && settings.device.lang &&
LANGS.includes(settings.device.lang)) {
lang = settings.device.lang;
}
//#endregion

View File

@ -394,7 +394,7 @@ export default Vue.extend({
yAxes: [{
ticks: {
callback: value => {
return Vue.filter('bytes')(value);
return Vue.filter('bytes')(value, 1);
}
}
}]
@ -403,7 +403,7 @@ export default Vue.extend({
callbacks: {
label: (tooltipItem, data) => {
const label = data.datasets[tooltipItem.datasetIndex].label || '';
return `${label}: ${Vue.filter('bytes')(tooltipItem.yLabel)}`;
return `${label}: ${Vue.filter('bytes')(tooltipItem.yLabel, 1)}`;
}
}
}

View File

@ -166,8 +166,8 @@ export async function createPerson(value: any, resolver?: Resolver): Promise<IUs
const avatarId = avatar ? avatar._id : null;
const bannerId = banner ? banner._id : null;
const avatarUrl = avatar && avatar.metadata.url ? avatar.metadata.url : null;
const bannerUrl = banner && banner.metadata.url ? banner.metadata.url : null;
const avatarUrl = (avatar && avatar.metadata.thumbnailUrl) ? avatar.metadata.thumbnailUrl : (avatar && avatar.metadata.url) ? avatar.metadata.url : null;
const bannerUrl = (banner && banner.metadata.url) ? banner.metadata.url : null;
await User.update({ _id: user._id }, {
$set: {
@ -255,7 +255,7 @@ export async function updatePerson(value: string | IObject, resolver?: Resolver)
sharedInbox: person.sharedInbox,
avatarId: avatar ? avatar._id : null,
bannerId: banner ? banner._id : null,
avatarUrl: avatar && avatar.metadata.url ? avatar.metadata.url : null,
avatarUrl: (avatar && avatar.metadata.thumbnailUrl) ? avatar.metadata.thumbnailUrl : (avatar && avatar.metadata.url) ? avatar.metadata.url : null,
bannerUrl: banner && banner.metadata.url ? banner.metadata.url : null,
description: htmlToMFM(person.summary),
followersCount,

View File

@ -84,7 +84,7 @@ export default async (params: any, user: ILocalUser, app: IApp) => new Promise(a
if (avatar == null) return rej('avatar not found');
updates.avatarUrl = avatar.metadata.url || `${config.drive_url}/${avatar._id}`;
updates.avatarUrl = avatar.metadata.thumbnailUrl || avatar.metadata.url || `${config.drive_url}/${avatar._id}`;
if (avatar.metadata.properties.avgColor) {
updates.avatarColor = avatar.metadata.properties.avgColor;