Unverified Commit 5135fd6b authored by Hong Minhee's avatar Hong Minhee
Browse files

Merge tag '0.11.3'

Fedify 0.11.3
parents ee80fd90 6045b822
Loading
Loading
Loading
Loading
+12 −0
Original line number Diff line number Diff line
@@ -128,6 +128,18 @@ To be released.
[Astro]: https://astro.build/


Version 0.11.3
--------------

Released on July 15, 2024.

 -  Fixed a bug where use of `Federation.setInboxDispatcher()` after
    `Federation.setInboxListeners()` had caused a `RouterError` to be
    thrown even if the paths match.  [[#101] by Fabien O'Carroll]

[#101]: https://github.com/dahlia/fedify/pull/101


Version 0.11.2
--------------

+12 −0
Original line number Diff line number Diff line
@@ -742,6 +742,18 @@ test("Federation.setInboxDispatcher()", async (t) => {
    );
  });

  await t.step("path match", () => {
    const federation = createFederation<void>({
      kv,
      documentLoader: mockDocumentLoader,
    });
    federation.setInboxListeners("/users/{handle}/inbox");
    federation.setInboxDispatcher(
      "/users/{handle}/inbox",
      () => ({ items: [] }),
    );
  });

  await t.step("wrong variables in path", () => {
    const federation = createFederation<void>({
      kv,
+1 −0
Original line number Diff line number Diff line
@@ -1545,6 +1545,7 @@ export class Federation<TContextData> {
          "Path for inbox must have one variable: {handle}",
        );
      }
      this.#inboxPath = inboxPath;
    }
    if (sharedInboxPath != null) {
      const siVars = this.#router.add(sharedInboxPath, "sharedInbox");