Closed mtuchi closed 1 year ago
Also when a user enter an invalid uuid
the following error will be thrown
See screen-record
https://github.com/OpenFn/Lightning/assets/6592749/e8b4043d-4d9c-4117-9a33-085c35ee4c20
@mtuchi , @elias-ba , this is already handled in a "good enough" sort of way on app.openfn.org.
in Phoenix, you only see that page that mtuchi shows when you're running an app on your local machine in dev mode. (and it's a great screen to see!)
Describe the bug
When a user enter a valid project
uuid
in url but that projectuuid
does not exist an error will be thrownI have reproduced this locally on main:
To Reproduce Steps to reproduce the behavior:
uuid
eg.abb2e086-8d79-42b2-94d1-b56c67cef5fb
Screenshots
Additional context This bug happens when project is
nil
when we're fetching the project in this line https://github.com/OpenFn/Lightning/blob/main/lib/lightning_web/hooks.ex#L19Proposed solution Check if project exist before checking for permission