 
        @main = false
        id = @node.id
-       id = @prevBlock.id if @prevBlock?
+       id = @prevNode.id if @prevNode?
        n = new Sidenote indentation: line.indentation + 1, link: id
        @mainNode = @node
        @node = n

     @node = @root
     @main = true
     @sidenotes = []
     @prevBlock = null
     @blocks = []

    parse: ->


     if line.empty
      if @node.type is TYPES.block
       @prevNode = @node
       @node = @node.parent()

      if @node.type is TYPES.codeBlock or @node.type is TYPES.html
