Changed this.author to doc.author as the former doesn't exist.