Skip to content
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

fix: abort handler manually after abnormal closure #40

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

nichtsen
Copy link

@nichtsen nichtsen commented Jun 3, 2022

i had ran the chatroom example on my local machine, however, when user closed the tab on browser, the handler just crashed with the following logs:

`[panic.go:838] the request url is /ws/join

[panic.go:838] Handler crashed with error can't find templatefile in the path:views/websocketcontroller/join.tpl
`

it seems that beego trys to find template and render after /ws/join handler return, which is not neccessary in the case. Instead, abort handler manually is suitable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant