Restructuring this meteor update snippet


#1

I have this snippet of code

		 Requestor.update({ _id: theid }, {$set: {
		  "reqestmadebyid": doc.reqestmadebyid,
		  "requestschoolid": doc.requestschoolid,
		  "requestmadebynames": doc.requestmadebynames,
		  "requestmadeon": doc.requestmadeon,
		  "requesttype": doc.requesttype,
		  "requestdescription": doc.requestdescription,
		  "requestparameter1": doc.requestparameter1,
		  "requestparameter2" : doc.requestparameter2,
		  "requestparameter3" : doc.requestparameter3,
		  "requestparameter4" : doc.requestparameter4,
		  "requestparameter5" : doc.requestparameter5,
		  "requestparameter6" : doc.requestparameter6,
		  "requestparameter7" : doc.requestparameter7,
		  "requeststatus" : doc.requeststatus,
		  "requestdenialexplanation" : doc.requestdenialexplanation
			 }
			 });

which i am using to update a form. Is there a way i can make it smaller like we do during insert?.


#2

This should work: Requestor.update({ _id: theid }, {$set: doc});


#3

Wow,i cant belive a that code is gone,thanks.