<FromGitter>
<raw-bin> Shouldn't that work given that B is derived from A ? It worked for the first hash in line 5 above ?
<FromGitter>
<raw-bin> Thanks
<FromGitter>
<Blacksmoke16> the gist of it is that `{"B" => B.new}` is typed as `Hash(String, B)` and doesn't allow `A`. need to tell the compiler that it should also allow `A` types via `{"B" => B.new} of String => A`
<FromGitter>
<raw-bin> Fair enough! Good to see it covered already.
taupiqueur has quit [Ping timeout: 240 seconds]
ejjfunky has quit [Ping timeout: 240 seconds]
taupiqueur has joined #crystal-lang
<FromGitter>
<kingsleyh> anyone know how to get the location hash info in Kemal? I have a redirect coming to my endpoint and it has the data I want in the location hash e.g. http://localhost:3000/data#token=123
<FromGitter>
<kingsleyh> I want to grab the token
<FromGitter>
<kingsleyh> Kemal only seems to have params.url, params.json, params.query - which are all empty in my case
<FromGitter>
<Blacksmoke16> pretty sure you cant because thats a fragment, not query param so its never sent to the server
<FromGitter>
<Blacksmoke16> i.e. would need some JS or something
<FromGitter>
<kingsleyh> ah I see - so I would have to catch it at the webfront end and not the Kemal server
<FromGitter>
<Blacksmoke16> yes
<FromGitter>
<kingsleyh> how inconvenient
<FromGitter>
<Blacksmoke16> if you're doing an oauth flow, make sure you're doing the right one. afaik there's one that you get a token directly, whereas you want the one that gives an auth code
<FromGitter>
<kingsleyh> I'm trying to do oauth with twitch
<FromGitter>
<kingsleyh> so I can use it to fetch user details
<FromGitter>
<kingsleyh> it says I need a token to make the request to the API to get the user details