 
       when TYPES.media
        @addNode new Media indentation: line.indentation + 1, media: @parseMedia line.text
-       @prevBlock = @node
+       @prevNode = @node
        return
 
       else

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

    parse: ->


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