Bunda
Bunda
CC#
Created by theholyhuub on 5/10/2023 in #help
❔ ✅ baddest coder ever
Sure, this might help get you started: https://youtu.be/jGD0vn-QIkg
15 replies
CC#
Created by TotallyJustin on 4/21/2023 in #help
✅ Blazor Serverside Google Authentication Error 400
And I would expect the google interface to complain about that beforehand.
9 replies
CC#
Created by TotallyJustin on 4/21/2023 in #help
✅ Blazor Serverside Google Authentication Error 400
I'm thinking, maybe it is not allowed to use https for localhost redirects but I'm not sure.
9 replies
CC#
Created by TotallyJustin on 4/21/2023 in #help
✅ Blazor Serverside Google Authentication Error 400
Can you link to the documentation? Also I don't get notified if not @mentioned
9 replies
CC#
Created by TotallyJustin on 4/21/2023 in #help
✅ Blazor Serverside Google Authentication Error 400
What I normally would do is create a route at let's say /oauth/google/callback and add some logic there if needed and at the end I will redirect to a different page where you want the user to land.
9 replies
CC#
Created by TotallyJustin on 4/21/2023 in #help
✅ Blazor Serverside Google Authentication Error 400
Does Google force you to use https://localhost:7541/sigin-google ?
9 replies
CC#
Created by Bunda on 3/15/2023 in #help
❔ How to properly handle exceptions between API controller and service layer?
Thanks! I will try and hack something together
13 replies
CC#
Created by Bunda on 3/15/2023 in #help
❔ How to properly handle exceptions between API controller and service layer?
A filter like that would be great! Any idea how would I implement this part using the middleware? I feel like I'm repeating myself over and over with the error handling..
var message = e.InnerException?.Message ?? e.ToString();

_logger.LogWarning("Failed to create RiskyUser with userRefId {userRefId}: {exception}", userRefId, message);
ModelState.AddModelError("UniqueConstraintException", message);

return ValidationProblem(title: "Bad Request", statusCode: 400);
var message = e.InnerException?.Message ?? e.ToString();

_logger.LogWarning("Failed to create RiskyUser with userRefId {userRefId}: {exception}", userRefId, message);
ModelState.AddModelError("UniqueConstraintException", message);

return ValidationProblem(title: "Bad Request", statusCode: 400);
13 replies
CC#
Created by Bunda on 3/15/2023 in #help
❔ How to properly handle exceptions between API controller and service layer?
Thanks for the info. I'm not sure but it is my understanding that when using nullable in a project I should not throw exceptions when not needed because of the performance hit that comes with it. Is that correct?
13 replies
CC#
Created by Bunda on 3/15/2023 in #help
❔ How to properly handle exceptions between API controller and service layer?
Hi, I've been reading about IExceptionFilter which can be configured globally. However it looks like I then have to return my own responses instead of using the ValidationProblem / ProblemDetail response, which I really like. Any idea on how that would work?
13 replies
CC#
Created by Bunda on 10/6/2022 in #help
Launch WinForms app when user inactive
Thanks for the useful resources. That gives me a few ideas already. Would creating a scheduled task as part of an installer be a viable option? Feels a bit hacky to me but I’m not that experienced and it could be great solution for all I know. What do you think?
13 replies