faustinoaq changed the topic of #amber to: Welcome to Amber Framework community! | https://amberframework.org | Developer happiness, productivity and bare metal performance | GH: https://github.com/amberframework | Docs: https://docs.amberframework.org | Gitter: https://gitter.im/amberframework/amber | IRC Logger: https://irclog.whitequark.org/amber | Amber::Server.start
_whitelogger has joined #amber
_whitelogger has joined #amber
_whitelogger has joined #amber
feepbot has quit [Ping timeout: 272 seconds]
feepbot has joined #amber
_whitelogger has joined #amber
_whitelogger has joined #amber
<FromGitter> <nsuchy> ```code paste, see link``` ⏎ ⏎ Problem with this ⏎ When I update my own user ⏎ It won't work unless I change the email ... [https://gitter.im/amberframework/amber?at=5cf2e0a5e41fe15e75f7112b]
<FromGitter> <nsuchy> @Blacksmoke16 pointed out the PR that fixes this
<FromGitter> <nsuchy> Next quetion though, is there a way my pipe can see which pipeline it was invoked under?
<FromGitter> <nsuchy> For example my Authentication pipeline should only restrict the user if it's the admin pipeline, but routes in the user pipeline aren't restricted
<FromGitter> <nsuchy> Tried `return call_next(context) if Amber::Server[:pipeline] == :web` which didn't work
<FromGitter> <nsuchy> the behavior of my pipe involves knowing which pipeline its invoked under
<FromGitter> <nsuchy> I see the pipeline is in logs
<FromGitter> <nsuchy> so it must be possible to access which pipeline something runs under
<pracabor> @nsuchy, just don't add your pipe to the pipeline which you don't want it to run with
<FromGitter> <nsuchy> pracabor: The idea I had in mind was to check if the pipeline was the :user or :admin pipeline and then either allow or require more checks
<FromGitter> <nsuchy> I decided instead to make separate pipelines that rely on the same session and that solves my challenge.
<FromGitter> <nsuchy> pipes*
<FromGitter> <nsuchy> I now have WebAuthenticate, UserAuthenticate, and AdminAuthenticate which check different things
<FromGitter> <nsuchy> Ideally I would've had it check the pipeline it is invoked under and keep all the logic in a single file, but this works too