But you saw this custom error page instead of a default 500 error message because Netlify supports custom error handling for Edge Functions
An error page doesn't have to be this ugly. You can direct the user to whatever you like and elegantly handle the error behind the scenes