janus_finalize_template should skip over empty templates