Commit graph

7 commits

Author SHA1 Message Date
Grafcube 99cdbb5d58
Multi webfinger response (#33)
* Add support for building webfinger for multiple URLs with type

Update `build_webfinger_response` to accept `Vec<(Url, Option<&str>)>`
where `Url` is the ActivityPub ID and `&str` is the optional type.

* Update docs for `build_webfinger_response`

* Update tests to use new `build_webfinger_response`

Tests and docs don't cover usage with some `kind` value.

* Run formatter with nightly

* Revert "Add support for building webfinger for multiple URLs with type"

This reverts commits until 3f70586e63.
This was a breaking change and should be made into a separate function.

* Add `build_webfinger_response_with_type`

* Construct links separately and update `build_webfinger_response`

- `build_webfinger_response` calls `build_webfinger_response_with_type`.
- Links are constructed in a separate variable.
- Update docs for `build_webfinger_response_with_type` to be clearer
about usage.
- TODO: Use `derive_builder` to simplify function.

* Extract properties into variable

* Remove `other` from docs
2023-04-04 21:56:34 +02:00
Grafcube 813d7943e1
Change username regex in webfinger (#34)
* Change username regex in webfinger

Changes the regex used for username in `extract_webfinger_name` to
include additional characters like '.' and '-'. This is the same regex
used in Mastodon.

* Add link to Mastodon regex
2023-04-02 21:32:54 +02:00
Felix Ableitner 072353fc41 Dont use apub in type names 2023-03-16 21:41:43 +01:00
Nutomic 6a65fa7c98
Changes to make Lemmy work with 0.4 (#29)
* Make it work with Lemmy

* working but needs cleanup

* almost everything working

* debug

* stack overflow fix
2023-03-16 02:11:48 +01:00
Nutomic 6b3a4f8942
Add verify methods back in, some more fixes (#28) 2023-03-09 22:09:44 +01:00
Felix Ableitner d94a2ed0fc live federation example 2023-03-08 22:16:43 +01:00
Felix Ableitner 32394696a5 move files 2023-03-06 16:19:43 +01:00