           (u/fail "collection task :sortby option value should implement IFn\n")
           :else
           (let [collection-paths (partial grouped-paths "collection")]
-            (render-pre-wrap collection-paths options :io.perun/collection)))))
+            (render-pre-wrap "collection" collection-paths options :io.perun/collection)))))
 
 (deftask inject-scripts
   "Inject JavaScript scripts into html files.

  that are required by `render-paths-fn`.

  Returns a boot `with-pre-wrap` result"
  [render-paths-fn options tracer]
  (let [tmp (boot/tmp-dir!)]
    (boot/with-pre-wrap fileset
      (let [render-paths (render-paths-fn fileset options)
            new-metadata (render-to-paths render-paths (:renderer options) tmp tracer)
            rm-files (keep #(boot/tmp-get fileset (-> % :entry :path)) (vals render-paths))]
        (perun/report-debug "render-pre-wrap" "removing files" rm-files)
        (-> fileset
            (boot/rm rm-files)
            (commit tmp)

          (for [[path render-data] data]
            (let [content (render-in-pod @render-pod renderer render-data)]
              (perun/create-file tmp path content)
              (perun/report-debug task-name "rendered page for path" path)
              (assoc (dissoc (:entry render-data) :content)
                     :path path
                     :has-content true))))))
