Fixed bad function calling

This commit is contained in:
Kenneth Jao 2016-08-13 20:24:56 -04:00
parent 57aeb4d34b
commit b1381234e2

View File

@ -251,9 +251,9 @@ Template.main.events({
if(e === "overlay") { if(e === "overlay") {
closeDivFade(document.getElementsByClassName("overlay")[0]); closeDivFade(document.getElementsByClassName("overlay")[0]);
if(!Session.get("newWork")) { if(!Session.get("newWork")) {
Session.set("serverData",getHomeworkFormData()) if(getHomeworkFormData() === null) return;
sendData("editWork"); Session.set("serverData",Session.get("currentWork"));
} else { sendData("editWork");
} }
Session.set("newWork",null); Session.set("newWork",null);
} }