Add template and fix node access.