Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
syuilo committed Feb 19, 2021
2 parents 49e6c2e + 8bd80eb commit d6c8b9b
Show file tree
Hide file tree
Showing 179 changed files with 5,699 additions and 964 deletions.
2 changes: 1 addition & 1 deletion .node-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v14.15.1
v14.15.4
30 changes: 0 additions & 30 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -240,36 +240,6 @@ SQLでは配列のインデックスは**1始まり**。
MongoDBの時とは違い、findOneでレコードを取得する時に対象レコードが存在しない場合 **`undefined`** が返ってくるので注意。
MongoDBは`null`で返してきてたので、その感覚で`if (x === null)`とか書くとバグる。代わりに`if (x == null)`と書いてください
### 簡素な`undefined`チェック
データベースからレコードを取得するときに、プログラムの流れ的に(ほぼ)絶対`undefined`にはならない場合でも、`undefined`チェックしないとTypeScriptに怒られます。
でもいちいち複数行を費やして、発生するはずのない`undefined`をチェックするのも面倒なので、`ensure`というユーティリティ関数を用意しています。
例えば、
``` ts
const user = await Users.findOne(userId);
// この時点で user の型は User | undefined
if (user == null) {
throw 'missing user';
}
// この時点で user の型は User
```
という処理を`ensure`を使うと
``` ts
const user = await Users.findOne(userId).then(ensure);
// この時点で user の型は User
```
という風に書けます。
もちろん`ensure`内部でエラーを握りつぶすようなことはしておらず、万が一`undefined`だった場合はPromiseがRejectされ後続の処理は実行されません。
``` ts
const user = await Users.findOne(userId).then(ensure);
// 万が一 Users.findOne の結果が undefined だったら、ensure でエラーが発生するので
// この行に到達することは無い
// なので、.then(ensure) は
// if (user == null) {
// throw 'missing user';
// }
// の糖衣構文のような扱いです
```
### Migration作成方法
```
npx ts-node ./node_modules/typeorm/cli.js migration:generate -n 変更の名前
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM node:14.15.1-alpine AS base
FROM node:14.15.4-alpine AS base

ENV NODE_ENV=production

Expand Down
Binary file added assets/mi-white.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions locales/ar-SA.yml
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ enterEmoji: "أدخل إيموجي"
unrenote: "إلغاء مشاركة الملاحظة"
quote: "اقتبس"
pinnedNote: "ملاحظة مدبسة"
pinned: "دبّسها على الصفحة الشخصية"
you: "أنت"
clickToShow: "اضغط للعرض"
sensitive: "محتوى حساس"
Expand Down Expand Up @@ -428,6 +429,9 @@ latestVersion: "آخر نسخة مستقرة"
usageAmount: "الإستخدام"
capacity: "السعة"
inUse: "مستخدم"
_email:
_follow:
title: "يتابعك"
_mfm:
mention: "أشر الى"
quote: "اقتبس"
Expand Down
12 changes: 10 additions & 2 deletions locales/de-DE.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ cantRenote: "Renote dieses Beitrags nicht möglich."
cantReRenote: "Renote einer Renote nicht möglich."
quote: "Zitieren"
pinnedNote: "Angepinnte Notiz"
pinned: "Anheften"
you: "Du"
clickToShow: "Klicke, um diesen Inhalt anzusehen"
sensitive: "NSFW"
Expand Down Expand Up @@ -437,6 +438,7 @@ signinWith: "Mit {x} anmelden"
signinFailed: "Anmeldung fehlgeschlagen. Überprüfe Benutzername und Passswort."
tapSecurityKey: "Tippe deinen Sicherheitsschlüssel an"
or: "Oder"
language: "Sprache"
uiLanguage: "Sprache der Benutzeroberfläche"
groupInvited: "Du wurdest in eine Gruppe eingeladen"
aboutX: "Über {x}"
Expand Down Expand Up @@ -700,7 +702,13 @@ capacity: "Kapazität"
inUse: "Verwendet"
editCode: "Code bearbeiten"
apply: "Anwenden"
receiveAnnouncementFromInstance: "Benachrichtigungen von der Instanz empfangen"
receiveAnnouncementFromInstance: "E-Mail-Benachrichtigungen von dieser Instanz empfangen"
emailNotification: "E-Mail-Benachrichtigungen"
_email:
_follow:
title: "Du hast einen neuen Follower"
_receiveFollowRequest:
title: "Du hast eine Follow-Anfrage erhalten"
_plugin:
install: "Plugins installieren"
installWarn: "Installiere bitte nur vertrauenswürdige Plugins."
Expand Down Expand Up @@ -1508,7 +1516,7 @@ _notification:
youGotPoll: "{name} hat auf deiner Umfrage abgestimmt"
youGotMessagingMessageFromUser: "{name} hat dir eine Chatnachricht gesendet"
youGotMessagingMessageFromGroup: "In die Gruppe {name} wurde eine Chatnachricht gesendet"
youWereFollowed: "Du hast einen neuen Follower"
youWereFollowed: "ist dir gefolgt"
youReceivedFollowRequest: "Du hast eine Follow-Anfrage erhalten"
yourFollowRequestAccepted: "Deine Follow-Anfrage wurde akzeptiert"
youWereInvitedToGroup: "Du wurdest in eine Gruppe eingeladen"
Expand Down
10 changes: 9 additions & 1 deletion locales/en-US.yml
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ cantRenote: "This post can't be renoted."
cantReRenote: "A renote can't be renoted."
quote: "Quote"
pinnedNote: "Pinned note"
pinned: "Pin to profile"
you: "You"
clickToShow: "Click to show"
sensitive: "NSFW"
Expand Down Expand Up @@ -437,6 +438,7 @@ signinWith: "Sign in with {x}"
signinFailed: "Unable to sign in. The username or password you entered is incorrect."
tapSecurityKey: "Tap your security key"
or: "Or"
language: "Language"
uiLanguage: "UI display language"
groupInvited: "Invited to group"
aboutX: "About {x}"
Expand Down Expand Up @@ -700,7 +702,13 @@ capacity: "Capacity"
inUse: "Used"
editCode: "Edit code"
apply: "Apply"
receiveAnnouncementFromInstance: "Receive notifications from the instance"
receiveAnnouncementFromInstance: "Receive Email notifications from this instance"
emailNotification: "Email notifications"
_email:
_follow:
title: "You've got a new follower"
_receiveFollowRequest:
title: "You've received a follow request"
_plugin:
install: "Install plugins"
installWarn: "Please do not install untrustworthy plugins."
Expand Down
4 changes: 4 additions & 0 deletions locales/es-ES.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ cantRenote: "No se puede renotar este post"
cantReRenote: "No se puede renotar una renota"
quote: "Citar"
pinnedNote: "Nota fijada"
pinned: "Fijar"
you: ""
clickToShow: "Click para ver"
sensitive: "Marcado como sensible"
Expand Down Expand Up @@ -651,6 +652,9 @@ backgroundColor: "Fondo"
accentColor: "Acento"
textColor: "Texto"
value: "Valores"
_email:
_follow:
title: "te ha seguido"
_registry:
key: "Clave"
keys: "Clave"
Expand Down
4 changes: 4 additions & 0 deletions locales/fr-FR.yml
Original file line number Diff line number Diff line change
Expand Up @@ -96,6 +96,7 @@ renoted: "Republier"
cantRenote: "Ce message ne peut pas être republié."
quote: "Citer"
pinnedNote: "Note épinglée"
pinned: "Épingler sur le profil"
you: "Vous"
clickToShow: "Cliquer pour afficher"
sensitive: "Contenu sensible"
Expand Down Expand Up @@ -648,6 +649,9 @@ closeAccount: "Fermer le compte"
usageAmount: "Utilisation"
capacity: "Capacité "
inUse: "utilisé"
_email:
_follow:
title: "Vous suit"
_registry:
key: "Clé "
keys: "Clé "
Expand Down
38 changes: 38 additions & 0 deletions locales/id-ID.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
---
_lang_: "Bahasa Jepang"
headlineMisskey: "Catatan terhubung jaringan"
introMisskey: "Selamat datang! Misskey adalah perangkat mikroblog tercatu bersifat sumber terbuka.\nMulailah menuliskan catatan, bagikan peristiwa terkini, serta ceritakan segala tentangmu.📡\nTunjukkan juga reaksimu pada catatan pengguna lain.👍\nMari jelajahi dunia baru🚀"
monthAndDay: "{day} {month}"
search: "Pencarian"
notifications: "Notifikasi"
Expand Down Expand Up @@ -44,9 +46,30 @@ sendMessage: "Kirim pesan"
copyUsername: "Salin nama pengguna"
searchUser: "Cari pengguna"
reply: "Balas"
loadMore: "Selebihnya"
showMore: "Selebihnya"
youGotNewFollower: "Sedang mengikuti"
receiveFollowRequest: "Permintaan mengikuti terkirim"
mention: "Panggilan"
files: "Berkas"
download: "Unduh"
driveFileDeleteConfirm: "Hapus {name}? Catatan dengan berkas terkait juga akan terhapus."
unfollowConfirm: "Berhenti mengikuti {name}?"
following: "Ikuti"
followers: "Pengikut"
followsYou: "Mengikuti Anda"
error: "Galat"
somethingHappened: "Terjadi kesalahan"
retry: "Coba lagi"
pageLoadError: "Gagal memuat halaman."
pageLoadErrorDescription: "Umumnya disebabkan jaringan atau tembolok perambah. Cobalah bersihkan tembolok peramban lalu tunggu sesaat sebelum mencoba kembali."
privacy: "Keleluasaan"
follow: "Ikuti"
unfollow: "Berhenti mengikuti"
cantReRenote: "Renote tidak dapat direnote"
quote: "Kutip"
pinnedNote: "Note yang disematkan"
pinned: "Sematkan ke profil"
you: "Anda"
clickToShow: "Klik untuk melihat"
sensitive: "Konten sensitif"
Expand Down Expand Up @@ -190,26 +213,41 @@ invites: "Undang"
invitations: "Undang"
smtpUser: "Nama Pengguna"
smtpPass: "Kata sandi"
_email:
_follow:
title: "Sedang mengikuti"
_mfm:
mention: "Panggilan"
quote: "Kutip"
emoji: "Emoji kustom"
search: "Pencarian"
_theme:
keys:
mention: "Panggilan"
_sfx:
notification: "Notifikasi"
chat: "Pesan"
_widgets:
notifications: "Notifikasi"
timeline: "Linimasa"
_cw:
show: "Selebihnya"
_visibility:
followers: "Pengikut"
_profile:
username: "Nama Pengguna"
_exportOrImport:
followingList: "Ikuti"
muteList: "Bisukan"
blockingList: "Blokir"
_rooms:
_roomType:
default: "Bawaan"
_notification:
youWereFollowed: "Sedang mengikuti"
_types:
follow: "Ikuti"
mention: "Panggilan"
quote: "Kutip"
reaction: "Reaksi"
_deck:
Expand Down
Loading

0 comments on commit d6c8b9b

Please sign in to comment.