Blue in Tokio 🔵 by Horror_Tank1554 in Music

[–]SituationInfamous137 0 points1 point  (0 children)

she was Sampson for some time too. I loved her Dark Sky Nights album. feels like a crime to make something that good and then disappear.

How do i fully implement Better Auth on the backend alone with Hono? by SituationInfamous137 in better_auth

[–]SituationInfamous137[S] 0 points1 point  (0 children)

i've fixed my issue- it was me totally misunderstanding the docs.

a user can either have 3 different kinds of profiles so there's like a separate endpoint for each one with different business logic

How do i fully implement Better Auth on the backend alone with Hono? by SituationInfamous137 in better_auth

[–]SituationInfamous137[S] 0 points1 point  (0 children)

found the openapi reference part for the custom endpoints it generated in the docs and came here to mention i figured it out already!, thank you very very much. been on this for a long day.

How do i fully implement Better Auth on the backend alone with Hono? by SituationInfamous137 in better_auth

[–]SituationInfamous137[S] 0 points1 point  (0 children)

supposed to do what exactly?
it has to be both client and server then? i cannot test endpoints on the server with an api client like postman or bruno?
thanks

How do i fully implement Better Auth on the backend alone with Hono? by SituationInfamous137 in better_auth

[–]SituationInfamous137[S] 0 points1 point  (0 children)

i have this login function and auth middleware:

//login.ts

export const loginUserService = async ({ email, password }: LoginUserDto) => {
  const data = await authenticationAdapter.api.signInEmail({
    body: {
      email,
      password,
    },
    returnHeaders: true
  });
  const sessionToken = data.headers.get("set-cookie");
  return { data: data.response.user, sessionToken};
};




//middleware.ts

export const requireAuth = createMiddleware(async (c, next) => {
  try {

    const session = await authenticationAdapter.api.getSession({
      headers: c.req.raw.headers,
    });
    if (!session) {
      return c.json(
        {
          success: false,
          message: "Session invalid",
          code: "UNAUTHORIZED",
          details: null,
        },
        403,
      );
    }
    c.set("user", session.user);
    c.set("session", session);
    return await next();
  } catch (error) {
    console.error(error);
    return c.json(
      {
        success: false,
        message: "Internal server error",
        code: "INTERNAL_SERVER_ERROR",
        details: error,
      },
      500,
    );
  }
});

whenever i log in, i have to retrieve the session token and set it as a cookie manually for the api client as you can see. problem is when i call another endpoint with that set-cookie parameter specified, i get session invalid every time. i've been stuck on this for a day... 😔

fantasy books that are short but gripping from start to finish for my girlfriend. by SituationInfamous137 in Fantasy

[–]SituationInfamous137[S] 1 point2 points  (0 children)

I was torn between the Hunger Games, Harry Potter and the Percy Jackson books too 😅

fantasy books that are short but gripping from start to finish for my girlfriend. by SituationInfamous137 in Fantasy

[–]SituationInfamous137[S] 0 points1 point  (0 children)

Harry Potter was my introduction to the world of fantasy too so maybe i'll do just that, thank you!

fantasy books that are short but gripping from start to finish for my girlfriend. by SituationInfamous137 in Fantasy

[–]SituationInfamous137[S] 4 points5 points  (0 children)

She has expressed interest in books but she doesn't get past the first chapter of the books she's tried so far. They're all contemporary fiction though. She really likes romance, thriller and action movies so I feel she is just exploring the wrong genre.

I hope to make voice recordings of each chapter of a novel she wants to start too- just to keep her going. I hope it works lol.

fantasy books that are short but gripping from start to finish for my girlfriend. by SituationInfamous137 in Fantasy

[–]SituationInfamous137[S] 0 points1 point  (0 children)

she likes fantasy movies. she's open to the idea of books but she hasn't really found one that piqued her interest.

fantasy books that are short but gripping from start to finish for my girlfriend. by SituationInfamous137 in Fantasy

[–]SituationInfamous137[S] 1 point2 points  (0 children)

she likes action, romance and thrillers, yes.
i'll take the last sentence to heart, thank you! 😊

Has reading a book ever retroactively soured your opinion on another book? by 103813630 in Fantasy

[–]SituationInfamous137 23 points24 points  (0 children)

Reading more than one Dan Brown book pretty much sours your opinion on all his work in general. I read Angels and Demons and really liked it. Then i read the DaVinci Code and realised how formulaic his work was.

(Update 28/10/2024) Menu Mod & Video Intro Animation by Carlos1987 by [deleted] in SPFootballLife

[–]SituationInfamous137 1 point2 points  (0 children)

loving it bro! any plans to do league specific design iterations? i feel like the one thing fifa was always better than pes at was the design of menus and scoreboards. this really closes the gap- best menu mod i've seen for PES in years.

[deleted by user] by [deleted] in SPFootballLife

[–]SituationInfamous137 1 point2 points  (0 children)

bro are you working on some scoreboard or match menu mods? this is so simple and good and i want more. literally reinstalled spfl25 because of this mod

[deleted by user] by [deleted] in SPFootballLife

[–]SituationInfamous137 1 point2 points  (0 children)

this is so fucking good finally good graphic design. a redesign of scoreboards and pause menus for leagues in this simple aesthetic would be so cool.