ChilliCream / hotchocolate-examples

MIT License
187 stars 137 forks source link

Tidy up blog sample 2021-01-20-logging #27

Closed nightroman closed 3 years ago

nightroman commented 3 years ago
nightroman commented 3 years ago

Anyone interested? Otherwise I am going to close, do not like it hanging in my TODO list :)

PascalSenn commented 3 years ago

@pkellner Do you want to have a look at this? :)

pkellner commented 3 years ago

I have no issues. Not sure is static matters. I'm sure I copied an example from place in the mini profiler repo.

nightroman commented 3 years ago

Let me make _miniProfiler the instance field and see if it's OK.

nightroman commented 3 years ago

Done, _miniProfiler is the instance field, it works this way with no issues. Also used is not null instead of != null for consistency.

nightroman commented 3 years ago

Not sure is static matters. I'm sure I copied an example from place in the mini profiler repo.

In theory static may start to misbehave in some realistic scenarios with concurrent requests.

PascalSenn commented 3 years ago

if @pkellner approves we can get it merged :) It's his blogpost so he should have the control over what changes go in :)

pkellner commented 3 years ago

I'm good.

nightroman commented 3 years ago

I'm good.

@PascalSenn Let's merge and move on :)