Fix double loading js scripts
Adds update, beforeUpdate and allowed fields to discussion model