fix: Update server capabilities as Akkoma has v1 filter support (#1238)

This commit is contained in:
Nik Clayton 2025-01-28 10:44:40 +01:00 committed by GitHub
parent c81bb0238e
commit ebdd5862cb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 9 additions and 2 deletions

View File

@ -398,6 +398,13 @@ data class Server(
c[ORG_JOINMASTODON_STATUSES_SCHEDULED] = "1.0.0".toVersion()
}
AKKOMA -> {
// https://akkoma.dev/AkkomaGang/akkoma/src/branch/develop/lib/pleroma/web/mastodon_api/controllers
// Akkoma only has v1 filters.
c[ORG_JOINMASTODON_FILTERS_CLIENT] = "1.1.0".toVersion()
c[ORG_JOINMASTODON_STATUSES_SCHEDULED] = "1.0.0".toVersion()
}
// Everything else. Assume:
//
// - server side filtering
@ -405,7 +412,7 @@ data class Server(
// - no translation
//
// This may be an incorrect assumption.
AKKOMA, FEDIBIRD, HOMETOWN, ICESHRIMP, PIXELFED, UNKNOWN -> {
FEDIBIRD, HOMETOWN, ICESHRIMP, PIXELFED, UNKNOWN -> {
c[ORG_JOINMASTODON_FILTERS_SERVER] = "1.0.0".toVersion()
c[ORG_JOINMASTODON_STATUSES_SCHEDULED] = "1.0.0".toVersion()
}

View File

@ -290,7 +290,7 @@ class ServerTest(
kind = AKKOMA,
version = "3.9.3-0-gd83f5f66f-blob".toVersion(),
capabilities = mapOf(
ORG_JOINMASTODON_FILTERS_SERVER to "1.0.0".toVersion(),
ORG_JOINMASTODON_FILTERS_CLIENT to "1.1.0".toVersion(),
ORG_JOINMASTODON_STATUSES_SCHEDULED to "1.0.0".toVersion(),
),
),