Fix double-binding to submit event

Fixes #916.