* Added User.popLocation() and User.popLocation() methods for temporarily storing a user's location, ie. to get back where the user came from when it was necessary to login
* Removed Root.searchSites() method (will be back later) * Added checks for empty searches in Site.search_action()
This commit is contained in:
parent
3d0fae4302
commit
1c3c51a0e1
7 changed files with 46 additions and 72 deletions
|
@ -225,6 +225,11 @@ Story.prototype.rotate_action = function() {
|
|||
};
|
||||
|
||||
Story.prototype.comment_action = function() {
|
||||
if (!User.require(User.REGULAR)) {
|
||||
User.pushLocation(this.href(req.action) + "#form");
|
||||
res.message = gettext("Please login to add a comment.");
|
||||
res.redirect(this.site.members.href("login"));
|
||||
}
|
||||
var comment = new Comment(this);
|
||||
if (req.postParams.save) {
|
||||
try {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue