typos; added afterCompile method