Arghh! I'm surrounded by bullshit!
C# doesn't have sum types. I'm begining to see this as a fatal problem, and maybe I really should move to F#.
Frickin' nginx didn't start after a reboot, because it couldn't reach one of the hosts its the proxy for.
Time to move the "replace nginx with traefik" plans forward I guess.
Don't know what to do about c# though. I think I need to have more of a think about the problem. Quack.
I'm re-writing the Hydra frontend stuff, and I'm moving code out of the controller. After the user has logged in they need to be shown a 'consent' screen that asks them to confirm that they're ok with the client getting access to their data.
However, under certain conditions the consent screen is skipped and the user can be redirected without seeing it.
I was returning two values from the function, a bool 'is skip needed' and a nullable string 'redirectTarget' that's set when skipNeeded is true. However, I can instead return two nullables, the redirect string, or the info needed to show the consent screen.
Quack indeed.