Commit graph

2242 commits

Author SHA1 Message Date
naskya
4c91e8e37f
Merge branch 'develop' into feat/antenna_limit 2024-04-22 05:51:22 +09:00
naskya
8140694a31
chore (backend): add comment 2024-04-22 05:47:22 +09:00
naskya
509690d84d
chore: meRenoteCount -> myRenoteCount 2024-04-22 05:43:58 +09:00
naskya
dc53447fa3
chore (API): we still use the word 'renote' in our code/API 2024-04-22 05:42:40 +09:00
naskya
9fef36e80c
chore (backend): add comment 2024-04-22 01:56:34 +09:00
naskya
2a30b4a536
Revert "refactor (backend): it turns out that sending the entire note object was redundant"
This reverts commit 3b65ebcb3e.
2024-04-22 01:47:56 +09:00
naskya
2fa0ca355d
Merge branch 'develop' into redis 2024-04-21 22:25:50 +09:00
Lhcfl
70e4d78f90 Merge branch 'develop' of https://firefish.dev/firefish/firefish into fix/use-pagination-in-note 2024-04-21 11:18:24 +08:00
Lhcfl
1dfc7c443b fix: Extensions should be converted to lowercase 2024-04-21 11:14:19 +08:00
Lhcfl
3917818c76 fix: #10451 Emoji pack imports randomly stop processing files 2024-04-21 11:05:19 +08:00
naskya
6b008c651a
chore (backend): remove (technically) incorrect TypeORM decorator field 2024-04-21 11:09:18 +09:00
naskya
d2dbfb37c7
chore (backend): reflect entity changes to the schema and repository 2024-04-21 10:59:02 +09:00
naskya
43570a54aa
chore: format 2024-04-21 10:44:54 +09:00
naskya
4d34e14dd8
Merge branch 'develop' into feat/drive-file-usage-hints 2024-04-21 10:42:25 +09:00
naskya
28f7ac1acd
fix (backend): typo 2024-04-21 10:31:00 +09:00
naskya
9f3396af21
chore (backend): translate Japanese comments into English 2024-04-21 10:30:13 +09:00
mei23
dc02a07774
fix (backend): add Cache-Control to Bull Dashboard 2024-04-21 09:29:00 +09:00
naskya
2760e7feee
chore (minor): use ** in lieu of Math.pow 2024-04-21 06:40:53 +09:00
naskya
488323cc8e
chore: format 2024-04-21 05:57:05 +09:00
naskya
3b65ebcb3e
refactor (backend): it turns out that sending the entire note object was redundant 2024-04-21 05:55:45 +09:00
naskya
b08175fb83
Merge branch 'develop' into redis 2024-04-20 23:15:58 +09:00
naskya
a2699e6687
chore (backend): fix imports 2024-04-20 23:04:12 +09:00
Lhcfl
39a229b875 fix: use MkPagination for replies 2024-04-20 20:55:47 +08:00
Lhcfl
35c7dccb49 fix: use MkPagination in notes for Quote, Boost, Reaction 2024-04-20 15:56:13 +08:00
naskya
77ded03330
Merge branch 'develop' into redis 2024-04-20 10:17:11 +09:00
naskya
f33c7c6c94
fix (backend): host and hostname was messed up 2024-04-20 08:48:48 +09:00
naskya
d41b462a89
fix (backend): fix redis key prefix 2024-04-20 07:43:09 +09:00
naskya
ccbd6178e4
refactor (backend): port add-note-to-antenna to backend-rs
I hit this bug: https://github.com/napi-rs/napi-rs/issues/2060
2024-04-20 07:18:39 +09:00
naskya
5c4a773ecf
chore (backend): qualify Node.js builtin modules 2024-04-20 03:09:18 +09:00
naskya
ccb17977c3
chore (minor, backend): use type import 2024-04-20 03:08:35 +09:00
naskya
def62ff1ce
chore (minor, backend): remove unused import 2024-04-20 03:04:34 +09:00
naskya
56038b174d
fix (backend): correct import path 2024-04-20 03:01:13 +09:00
naskya
037b7950a2
refactor (backend): clean the booting process a bit 2024-04-20 02:58:39 +09:00
naskya
3b89a8bfa6
refactor (backend): port config loader to backend-rs completely 2024-04-20 02:46:37 +09:00
yumeko
6c46bb56fd
Switch DriveFile's usageHint field to an enum type 2024-04-19 18:24:48 +03:00
yumeko
968657d26e
Run format 2024-04-19 07:54:11 +03:00
yumeko
913de651db
When updating (remote) user avatar/banner, clear usageHint for the previous drivefile, if any 2024-04-19 07:25:42 +03:00
yumeko
c0f93de94b
Set file usage hints on local avatar/banner uploads as well + export "valid" values as type 2024-04-19 06:29:28 +03:00
yumeko
4823abd3a9
Add usageHint field to DriveFile, and fill accordingly when operating on Persons 2024-04-19 03:41:36 +03:00
naskya
c6e2776298
chore (backend): remove a horrible and unused function 2024-04-19 03:42:49 +09:00
naskya
4b7724ed1f Merge branch 'cw-text' into 'develop'
Increase CW character limit

Closes #10876

See merge request firefish/firefish!10746
2024-04-17 20:47:40 +00:00
naskya
1b076c96d7
Merge branch 'develop' into refactor/types 2024-04-18 05:10:20 +09:00
naskya
c19c439ac1
fix (backend): add hasPoll to packed note 2024-04-18 05:08:14 +09:00
naskya
cc452da6c5
Merge branch 'develop' into refactor/types 2024-04-18 05:03:32 +09:00
naskya
30969ad817
refactor (backend): port get-note-summary to backend-rs
I removed trim() as it wasn't strictly neccessary
2024-04-18 05:02:00 +09:00
naskya
8337863ed3
chore: format 2024-04-18 05:01:49 +09:00
naskya
6a94d1b65d Merge branch 'fix/server-stats-disable' into 'develop'
Fix check for whether stats are disabled in meta in server machine stats job

Co-authored-by: yumeko <yumeko@mainichi.social>

See merge request firefish/firefish!10748
2024-04-17 18:20:35 +00:00
naskya
c471aa30ae Merge branch 'fix/pinned-user-null' into 'develop'
Fix internal error in api/pinned-users if one or more name fails to resolve

Co-authored-by: yumeko <yumeko@mainichi.social>

See merge request firefish/firefish!10747
2024-04-17 18:19:17 +00:00
yumeko
a411f4e4d9 Fix internal error in api/pinned-users if one or more name fails to resolve 2024-04-17 18:19:17 +00:00
naskya
adaaae1583
Merge branch 'develop' into refactor/types 2024-04-17 19:07:43 +09:00
naskya
17fb05430e
fix (backend, Mastodon API): add 'meta.original' field to media attachments
addresses https://github.com/whitescent/Mastify/pull/102
2024-04-17 17:46:23 +09:00
yumeko
bf3c0717b9 Fix check for whether stats are disabled in meta in server machine stats job 2024-04-16 15:29:18 +00:00
naskya
082948bfe0
Merge branch 'develop' into refactor/types 2024-04-16 22:29:04 +09:00
naskya
07384a4f0f
feat (backend): increase CW character limit (close #10876) 2024-04-16 09:14:44 +09:00
naskya
fd333250c9
chore (backend): set proxyRemoteFiles to true by default (close #9426) 2024-04-16 08:56:05 +09:00
naskya
80b80277e2
fix (pug): random MOTD not showing 2024-04-16 01:50:42 +09:00
naskya
71c158fbd3
refactor (backend): port env.ts to backend-rs 2024-04-15 17:28:20 +09:00
naskya
0f3126196f
refactor (backend): port reaction-lib to backend-rs 2024-04-15 10:02:44 +09:00
naskya
2731003bc9
refactor (backend): port emoji-regex to backend-rs 2024-04-15 05:37:09 +09:00
naskya
74875f174b
chore (minor, backend): use a template literal 2024-04-15 04:34:36 +09:00
naskya
884c69f377
chore (minor, backend): organize imports 2024-04-15 04:34:00 +09:00
naskya
f412d7ace3
chore (backend): remove 'quiet' settings 2024-04-15 04:31:04 +09:00
naskya
21225f7137
chore: update dependencies 2024-04-15 04:09:33 +09:00
naskya
fca48b2a81
refactor (backend): port safe-for-sql, sql-like-escape to backend-rs 2024-04-14 20:29:44 +09:00
sup39
b71da18b03
refactor (backend): port fetch-meta to backend-rs
Co-authored-by: naskya <m@naskya.net>
2024-04-14 20:16:22 +09:00
Lhcfl
241c824ab5 fix: use better ]]> replacer 2024-04-14 16:44:12 +08:00
Lhcfl
54d9916fec fix: rss feed no HTML 2024-04-14 16:34:33 +08:00
naskya
ceca260c92
refactor (backend): port convert-milliseconds to backend-rs 2024-04-14 14:54:32 +09:00
sup39
70aa3704ef
refactor (backend): port password hashing/verification to backend-rs
Co-authored-by: naskya <m@naskya.net>
2024-04-14 14:41:01 +09:00
Lhcfl
bb9a58ce34 Merge branch 'develop' of https://firefish.dev/firefish/firefish into refactor/types 2024-04-13 20:08:41 +08:00
naskya
ad58ae8f30
refactor: remove /api/patrons endpoint 2024-04-13 20:03:02 +09:00
Lhcfl
f95e2d1c51 Merge branch 'develop' of https://firefish.dev/firefish/firefish into refactor/types 2024-04-13 15:39:44 +08:00
老周部落
5eff4da27b
feat: antenna limit 2024-04-13 10:02:32 +08:00
老周部落
f44a2937d4
fix: download-url should use proxy bypass hosts 2024-04-13 09:00:08 +08:00
naskya
603ec70b97
refactor (backend-rs): rewrite Mastodon ID conversion
Co-authored-by: sup39 <dev@sup39.dev>
2024-04-12 21:48:55 +09:00
naskya
148c3736ce
refactor (backend): port convert-host to backend-rs
Co-authored-by: sup39 <dev@sup39.dev>
2024-04-12 17:13:57 +09:00
naskya
3d6031dca3
chore: get rid of re2 from dependencies 2024-04-12 15:47:04 +09:00
naskya
83c15b1026
refactor (backend): port checkWordMute to backend-rs
Co-authored-by: sup39 <dev@sup39.dev>
2024-04-12 15:43:17 +09:00
naskya
e2cd25ea4f
refactor (backend): port config loader to backend-rs
Co-authored-by: sup39 <dev@sup39.dev>
2024-04-12 14:25:27 +09:00
naskya
ad30d16f23
chore (backend): remove unused file 2024-04-12 11:10:52 +09:00
naskya
452e0b921c
refactor (backend): port acct to backend-rs 2024-04-12 11:10:52 +09:00
naskya
beb16ab9cf
refactor (backend): port nyaify to backend-rs 2024-04-12 11:10:42 +09:00
naskya
f60ff2eaf4
refactor (backend-rs): rewrite id generator
Co-authored-by: sup39 <dev@sup39.dev>
2024-04-12 05:20:45 +09:00
naskya
3fe8ace571
chore: update dependencies 2024-04-12 02:55:27 +09:00
naskya
afc57d834c
fix (backend): add missing Relation wrapper
should have done in aedf873248
2024-04-12 02:42:17 +09:00
naskya
24f79d4796
fix (backend): prevent chat messages from being deleted when attached file is deleted 2024-04-12 02:26:00 +09:00
Lhcfl
8e28f0e97c Merge branch 'develop' of https://firefish.dev/firefish/firefish into refactor/types 2024-04-12 00:23:21 +08:00
Lhcfl
d8b4eb6f5e fix: gallery posts not show & fix types 2024-04-12 00:22:49 +08:00
naskya
aedf873248
refactor (backend): distinguish between database columns and relations, set correct nullability 2024-04-11 21:58:06 +09:00
Lhcfl
6982843716 fix: channel editor cannot remove channel banner 2024-04-10 22:25:45 +08:00
Lhcfl
23145c61af refactor: fix type of MkAbuseReport 2024-04-10 17:55:52 +08:00
naskya
c707221dfb
chore (minor): use type import 2024-04-08 21:15:18 +09:00
naskya
e1345e4e29
fix (backend): make sure that instance info fit in the database (close #10891)
I guess there is a better way to do this...
2024-04-08 20:52:14 +09:00
naskya
30619301d3
chore: replace new Date().getTime() with Date.now()
959cc8ff37

Co-authored-by: zyoshoka <107108195+zyoshoka@users.noreply.github.com>
2024-04-08 17:00:41 +09:00
naskya
fce0e5a218
feat (backend): federate math expressions using MathML
Co-authored-by: Johann150 <johann.galle@protonmail.com>
2024-04-08 12:15:54 +09:00
naskya
9df08ea16a
refactor (minor): replace substr with substring 2024-04-07 19:10:26 +09:00
naskya
26c3b25a40
chore: update dependencies 2024-04-07 16:42:25 +09:00
naskya
110e092262
chore (backend): use type import for MigrationInterface and QueryRunner 2024-04-07 12:38:52 +09:00
naskya
5c0d771dff
chore: await migration queries 2024-04-07 12:16:53 +09:00
naskya
383b2b874d
chore: format 2024-04-07 05:06:42 +09:00
naskya
91ccce4307
refactor (backend): drop timezone data (which is not used at all)
Co-authored-by: sup39 <dev@sup39.dev>
2024-04-07 05:06:27 +09:00
naskya
54c5192a06
chore (backend): add some more comments on the translate function 2024-04-06 07:42:32 +09:00
Lhcfl
e8f178458f Merge branch 'develop' of https://firefish.dev/firefish/firefish into feat/note-edit-history 2024-04-01 11:32:14 +08:00
Lhcfl
0b226f7013 store emojis for note_edit 2024-04-01 11:01:59 +08:00
Lhcfl
a562d9bb39 chore: format 2024-04-01 03:24:30 +08:00
Laura Hausmann
88ca0e1621
fix (backend): set X-Content-Type-Options to nosniff on the drive files endpoint 2024-04-01 03:22:06 +09:00
Lhcfl
cbe88c56ef feat: show files of noteEdit 2024-04-01 01:53:21 +08:00
Lhcfl
6d4cb5b4aa fix: note.updatedAt might be null 2024-04-01 00:40:58 +08:00
naskya
b3668f67a0
fix (backend): check redirect url 2024-03-30 19:01:28 +09:00
Laura Hausmann
e753b313da
fix (backend): reject anonymous objects 2024-03-30 19:01:28 +09:00
Laura Hausmann
2e51a33ae5
fix (backend): stricter hostname checking when fetching remote objects
Co-authored-by: naskya <m@naskya.net>
2024-03-30 19:01:28 +09:00
Laura Hausmann
ada0137a35
fix (backend): verify object id host matches final URL when fetching remote activities
5f6096c1b7

Co-authored-by: naskya <m@naskya.net>
2024-03-30 19:01:28 +09:00
Laura Hausmann
850c52ef63
feat (backend): permit redirects for AP object lookups
8d7d95fd23

Co-authored-by: naskya <m@naskya.net>
2024-03-30 19:01:28 +09:00
naskya
00b15bb17c
refactor (backend): mark resolveLocal as async
There are many type errors that need to be fixed :(
2024-03-30 19:01:16 +09:00
mei23
ce69001243
fix (backend): improve URL check
13ea67bee4
da12d5b079

Co-authored-by: naskya <m@naskya.net>
2024-03-30 18:10:52 +09:00
naskya
293afc7fe4
Merge branch 'develop' into feat/note-edit-history 2024-03-28 14:27:29 +09:00
naskya
611a2f02b9
chore: format 2024-03-28 14:26:09 +09:00
naskya
284f077dba Merge branch 'ft/run-linter' into 'develop'
chore: format

Co-authored-by: deathg.rip <josh@deathg.rip>

See merge request firefish/firefish!10707
2024-03-28 05:25:33 +00:00
Nyan Helsing
a98a26e901 chore: format
Co-authored-by: deathg.rip <josh@deathg.rip>
2024-03-28 05:25:33 +00:00
naskya
6cd5dc2fcb
chore: update dependencies
except for adm-zip
2024-03-26 20:46:44 +09:00
naskya
5e2b8d3be0
chore: add a function to compare two arrays 2024-03-26 19:43:11 +09:00
naskya
d1d0328f8b
fix (backend): update note_file on note edits
TODO: move these processes to services/note/edit.ts
2024-03-26 19:42:19 +09:00
naskya
bd5e95a1f0
chore: remove unused import 2024-03-26 19:13:38 +09:00
Lhcfl
bab704992f feat: add post history page 2024-03-26 16:59:42 +08:00
Lhcfl
d64d133d7f backend: added /note/history endpoint 2024-03-26 10:07:00 +08:00
naskya
8b01433f2b
Revert "Merge branch 'feat/proxy_media_fallback' into 'develop'"
This reverts commit a7d6e8eb1a, reversing
changes made to 1871dacd8d.
2024-03-26 04:09:01 +09:00
Linca
72d5e4cdb8 fix: #10868 incorrect text inserted to note_edit
Co-authored-by: Lhcfl <Lhcfl@outlook.com>
2024-03-25 17:02:02 +00:00
naskya
17cd5ecfc2 Merge branch 'feat/server_nsfw' into 'develop'
feat: admin ability to force drive content to always be nsfw

Co-authored-by: 老周部落 <laozhoubuluo@gmail.com>

Closes #10713

See merge request firefish/firefish!10685
2024-03-25 15:03:16 +00:00
老周部落
05e5e92ef3
feat: admin ability to force drive content to always be nsfw 2024-03-25 21:15:53 +08:00
naskya
a7d6e8eb1a Merge branch 'feat/proxy_media_fallback' into 'develop'
feat: proxy media fallback and url preview fallback

Co-authored-by: 老周部落 <laozhoubuluo@gmail.com>

See merge request firefish/firefish!10693
2024-03-24 17:37:59 +00:00
Linca
ed72aab48e
fix (backend): downgrade adm-zip to v0.5.10
To workaround this problem: https://github.com/cthackers/adm-zip/issues/475

Co-authored-by: naskya <m@naskya.net>
2024-03-24 20:45:02 +09:00
naskya
ad08d071bf Merge branch 'change-from-html' into 'develop'
refactor: Rewrite from-html parser using recursion

Co-authored-by: Lhcfl <Lhcfl@outlook.com>

See merge request firefish/firefish!10694
2024-03-23 16:34:44 +00:00
Linca
7c761f8c3d refactor: Rewrite from-html parser using recursion
Co-authored-by: Lhcfl <Lhcfl@outlook.com>
2024-03-23 16:34:44 +00:00
naskya
83944dd49f
chore: update dependencies 2024-03-23 21:41:51 +09:00
naskya
6e9d3387e0
refactor (backend): use Promise.all to await multiple async processes 2024-03-23 00:54:54 +09:00
naskya
26e35d1d82
refactor: make function name clearer, let the ORM build queries 2024-03-20 19:17:46 +09:00
naskya
dc2039b45a
refactor (backend): change variable name, await asyncronous processes 2024-03-20 18:45:50 +09:00
naskya
7e2559c5ee
Merge branch 'develop' into catofish-fix/local-user-notes-count 2024-03-20 18:34:33 +09:00
老周部落
2af7f48870
feat: proxy media fallback and url preview fallback 2024-03-18 18:30:42 +08:00
naskya
f7a8a58cb2
Revert "refactor: remove note.mentionedRemoteUsers column"
This reverts commit 65797a934a.
2024-03-18 03:29:19 +09:00
naskya
e4a72bbfe5
Revert "backend: improve removeMentionedRemoteUsersColumn revert query (#403)"
This reverts commit 3473442875.
2024-03-18 03:29:17 +09:00
Linca
d002741ecc Merge branch 'develop' into 'fix/local-user-notes-count'
# Conflicts:
#   packages/backend/src/services/note/delete.ts
2024-03-17 16:24:50 +00:00
sup39
9fd9eb0100
fix (backend): incorrect database queries 2024-03-18 01:01:54 +09:00
naskya
c61e6cd255
fix (backend): incorrect database indices (renote_mute & reply_mute) 2024-03-18 01:01:54 +09:00
Norm
3473442875
backend: improve removeMentionedRemoteUsersColumn revert query (#403)
This is an optimized version made by Volpeon that should run faster if
the instance has a lot of notes.

See <https://is-a.wyvern.rip/notes/9habqldl6j> for a comparison of the
EXPLAIN ANALYZE of the old and new queries.

Co-authored-by: Volpeon <git@volpeon.ink>

Reviewed-on: https://akkoma.dev/FoundKeyGang/FoundKey/pulls/403
2024-03-18 00:20:02 +09:00
Johann150
65797a934a
refactor: remove note.mentionedRemoteUsers column
The column mentionedRemoteUsers on the note table in the database is
firstly in the wrong type since it contains JSON data but is typed as
text. Secondly it seems redundant, since that data can be acquired by
using the note.mentions column to fetch the respective data instead.

Co-authored-by: Francis Dinh <normandy@biribiri.dev>
2024-03-18 00:16:49 +09:00
sup39
9bce737f67
fix (backend): add alias to a migration subquery
Co-authored-by: naskya <m@naskya.net>
2024-03-17 23:13:54 +09:00
sup39
cca63b7286
perf (backend): improved post search with CW/alt text
Co-authored-by: naskya <m@naskya.net>
2024-03-17 22:40:36 +09:00
naskya
2220d5c56e
refactor (backend): add note_file table to store (noteId, fileId) pairs
Co-authored-by: sup39 <dev@sup39.dev>
2024-03-17 22:40:35 +09:00
naskya
0f880b55e3
chore (backend): add FIXME to a questionable database column 2024-03-17 22:40:35 +09:00