Fixed edit_mode variable in snippets controller