corrected newPoll to this since this is an already existing object.

This commit is contained in:
Tobi Schäfer 2002-02-01 17:23:07 +00:00
parent 8a12560849
commit 83b010100f

View file

@ -35,7 +35,7 @@ function evalPoll(param, creator) {
if (!title) if (!title)
continue; continue;
var newChoice = new choice(); var newChoice = new choice();
newChoice.poll = newPoll; newChoice.poll = this;
newChoice.title = title; newChoice.title = title;
newChoice.createtime = new Date(); newChoice.createtime = new Date();
newChoice.modifytime = new Date(); newChoice.modifytime = new Date();
@ -44,7 +44,7 @@ function evalPoll(param, creator) {
result.url = path.weblog.polls.href(); result.url = path.weblog.polls.href();
result.message = "The poll was updated successfully!"; result.message = "The poll was updated successfully!";
result.id = newPoll._id; result.id = this._id;
result.error = false; result.error = false;
} }
else { else {