New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Consider missingView as action #460

Closed
seancorfield opened this Issue Nov 28, 2016 · 5 comments

Comments

Projects
None yet
2 participants
@seancorfield
Member

seancorfield commented Nov 28, 2016

This arose from #fw1-clj/51 which is looking at a missing view handler for the Clojure version. Given that the default error handling is an actual action (where we reset everything and run a new action), could missing view be handled in a similar way? This would probably be more flexible (and more consistent) than the current missing view handling machinery.

@dnando

This comment has been minimized.

Show comment
Hide comment
@dnando

dnando Nov 28, 2016

dnando commented Nov 28, 2016

@seancorfield

This comment has been minimized.

Show comment
Hide comment
@seancorfield

seancorfield Nov 28, 2016

Member

Well, technically the exception is still thrown, but this allows you to specify a different error action to handle it. This is "simpler" since the new missingview action will occur in a fresh context from start to finish, just like a regular action (just as error actions work now). Previously, you could only intercept the view() call (essentially) and you had to just return a rendered view directly.

Member

seancorfield commented Nov 28, 2016

Well, technically the exception is still thrown, but this allows you to specify a different error action to handle it. This is "simpler" since the new missingview action will occur in a fresh context from start to finish, just like a regular action (just as error actions work now). Previously, you could only intercept the view() call (essentially) and you had to just return a rendered view directly.

@dnando

This comment has been minimized.

Show comment
Hide comment
@dnando

dnando Nov 28, 2016

dnando commented Nov 28, 2016

@seancorfield

This comment has been minimized.

Show comment
Hide comment
@seancorfield

seancorfield Nov 28, 2016

Member

FYI @dnando when you reply by email to a GH comment, your phone number and Skype handle end up publicly visible in these threads. I've edited them out above but wanted to let you know.

Member

seancorfield commented Nov 28, 2016

FYI @dnando when you reply by email to a GH comment, your phone number and Skype handle end up publicly visible in these threads. I've edited them out above but wanted to let you know.

@dnando

This comment has been minimized.

Show comment
Hide comment
@dnando

dnando Nov 29, 2016

dnando commented Nov 29, 2016

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment