You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to upgrade a dependency on 3.3.3 to the latest and I've hit a snag. We were passing nil to Router.Route()'s fn param so that later routes would get added as sub-routes to it. But as of this commit that causes a panic.
It looks like I can achieve the same thing by passing a no-op func instead of nil, but... is there something wrong with doing that? What was the reason for the change that added the panic? I don't want to naively bypass the panic and maybe reintroduce something bad that the panic was designed to detect.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I'm trying to upgrade a dependency on 3.3.3 to the latest and I've hit a snag. We were passing nil to
Router.Route()
'sfn
param so that later routes would get added as sub-routes to it. But as of this commit that causes a panic.It looks like I can achieve the same thing by passing a no-op func instead of nil, but... is there something wrong with doing that? What was the reason for the change that added the panic? I don't want to naively bypass the panic and maybe reintroduce something bad that the panic was designed to detect.
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions