 			console.log doc
 			doc
 		else
-			null+			null

				filename = file
				src = filename
		if filename
			obj = 
				template: getTemplate(filename)
				data:
					src: src

		if af &&  af.submitType == 'insert'
			doc = af.doc

		parentData = Template.parentData(0).value or Template.parentData(4).value
		if Session.equals('fileUpload['+name+']', 'delete-file')
			return null
		else if Session.get('fileUpload['+name+']')
			file = Session.get('fileUpload['+name+']')
		else if parentData
			file = parentData
		else
			return null

