# SOLVED: Cannot create new nodes: error \`Template needs to specify ‘:if-new’\`

**URL:** <https://org-roam.discourse.group/t/solved-cannot-create-new-nodes-error-template-needs-to-specify-if-new/1797>\
**Category:** Troubleshooting\
**Created:** [July 21, 2021, 6:04pm UTC](https://org-roam.discourse.group/t/solved-cannot-create-new-nodes-error-template-needs-to-specify-if-new/1797 "2021-07-21T18:04:15Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![JeffBrown](https://yyz2.discourse-cdn.com/free1/user_avatar/org-roam.discourse.group/jeffbrown/32/254_2.png) [@JeffBrown](https://org-roam.discourse.group/u/JeffBrown)\
**Post date:** [July 21, 2021, 6:04pm UTC](https://org-roam.discourse.group/t/solved-cannot-create-new-nodes-error-template-needs-to-specify-if-new/1797/1 "2021-07-21T18:04:16Z")

</div>

Since upgrading to v2 I cannot create new nodes.

When I try, I am as in v1 first asked to “Select a capture template”, and presented with the menu that used to cause me to write into one of the three folders I use (public notes, private notes, and work notes). But when I select one, I get

```auto
user-error: Template needs to specify ‘:if-new’

```

Here’s the code (which I’ve carried over from org-roam v1) that defines my templates:

```auto
(setq org-roam-capture-templates
      ;; These folder names are dumb, but to change them I would need
      ;; to change every link involving them.
      '( ( "u" "public" plain
           (function org-roam--capture-get-point)
           "%?"
           :file-name "tech/%<%Y%m%d%H%M%S>-${slug}"
           :head "#+title: ${title}\n"
           :unnarrowed t)
         ( "r" "private" plain
	   ... )
         ( "o" "ofiscal" plain
	   ... )
         ))

```

Has it gone stale?

The last option in the menu I’m presented with is “[C] Customize org-roam templates”. Selecting that gives me this error:

```auto
Debugger entered--Lisp error: (invalid-read-syntax "#")
  read("\n'((\"u\" \"public\" plain #'org-roam-capture--get-poi...")
  ... <Here I'm omimtting a few really long expressions because Discourse doesn't want that many characters> ...
  widget-create(custom-variable :documentation-shown t :custom-state unknown :tag "Org Capture Templates" :value org-capture-templates)
  #f(compiled-function (entry) #<bytecode 0xc7a00d>)((org-capture-templates custom-variable))
  mapcar(#f(compiled-function (entry) #<bytecode 0xc7a00d>) ((org-capture-templates custom-variable)))
  custom-buffer-create-internal(((org-capture-templates custom-variable)))
  custom-buffer-create(((org-capture-templates custom-variable)) "*Customize Option: Org Capture Templates*")
  customize-variable(org-capture-templates)
  org-capture(nil nil)
  org-roam-capture-(:node #s(org-roam-node :file nil :file-hash nil :file-atime nil :file-mtime nil :id nil :level nil :point nil :todo nil :priority nil :scheduled nil :deadline nil :title "wuh" :properties nil :olp nil :tags nil :aliases nil :refs nil) :props (:finalize find-file :call-location #<marker at 8944 in 20200610061525-org_roam.org>))
  org-roam-node-find()
  funcall-interactively(org-roam-node-find)
  call-interactively(org-roam-node-find nil nil)
  command-execute(org-roam-node-find)

```

---

<div class="post-metadata">

**Author:** ![nobiot](https://yyz2.discourse-cdn.com/free1/user_avatar/org-roam.discourse.group/nobiot/32/159_2.png) [@nobiot](https://org-roam.discourse.group/u/nobiot)\
**Post date:** [July 21, 2021, 6:07pm UTC](https://org-roam.discourse.group/t/solved-cannot-create-new-nodes-error-template-needs-to-specify-if-new/1797/2 "2021-07-21T18:07:37Z")

</div>

have a look at the docstring of org-roam-capture-templates and manual.  
it has gone through a major update. you need to have :if-new, really.

---

<div class="post-metadata">

**Author:** ![JeffBrown](https://yyz2.discourse-cdn.com/free1/user_avatar/org-roam.discourse.group/jeffbrown/32/254_2.png) [@JeffBrown](https://org-roam.discourse.group/u/JeffBrown)\
**Post date:** [July 21, 2021, 7:15pm UTC](https://org-roam.discourse.group/t/solved-cannot-create-new-nodes-error-template-needs-to-specify-if-new/1797/4 "2021-07-21T19:15:08Z")

</div>

It works! Thanks, @nobiot!

I found aping [Jethro’s own `.emacs` file](https://github.com/jethrokuan/dots/blob/master/.doom.d/config.el#L350-L356) helpful.
