mirror of
https://github.com/reddit-archive/reddit.git
synced 2026-04-05 03:00:15 -04:00
Allow gold users to optionally receive inbox replies to posts.
This commit is contained in:
@@ -374,7 +374,8 @@ class ApiController(RedditController, OAuth2ResourceController):
|
||||
form.set_error(errors.QUOTA_FILLED, None)
|
||||
return
|
||||
|
||||
sendreplies = kind == 'self'
|
||||
if not c.user.gold or not hasattr(request.post, 'sendreplies'):
|
||||
sendreplies = kind == 'self'
|
||||
|
||||
# well, nothing left to do but submit it
|
||||
l = Link._submit(request.post.title, url if kind == 'link' else 'self',
|
||||
|
||||
@@ -67,7 +67,6 @@ class Link(Thing, Printable):
|
||||
pending=False,
|
||||
disable_comments=False,
|
||||
selftext='',
|
||||
noselfreply=False,
|
||||
sendreplies=True,
|
||||
ip='0.0.0.0',
|
||||
flair_text=None,
|
||||
@@ -744,7 +743,7 @@ class Comment(Thing, Printable):
|
||||
name = 'inbox'
|
||||
if parent:
|
||||
to = Account._byID(parent.author_id, True)
|
||||
elif link.is_self and not link.noselfreply:
|
||||
elif link.sendreplies:
|
||||
to = Account._byID(link.author_id, True)
|
||||
name = 'selfreply'
|
||||
|
||||
|
||||
@@ -5333,6 +5333,10 @@ body:not(.gold) .allminus-link {
|
||||
max-width: 550px;
|
||||
}
|
||||
|
||||
.gold-accent.roundfield {
|
||||
margin-top: 0px;
|
||||
}
|
||||
|
||||
.gold-form {
|
||||
font-family: "Hoefler Text","Palatino Linotype","Book Antiqua", Palatino,georgia,garamond,FreeSerif,serif;
|
||||
min-height: 600px;
|
||||
|
||||
@@ -103,6 +103,18 @@ ${thing.formtabs_menu}
|
||||
</%utils:round_field>
|
||||
</div>
|
||||
|
||||
%if c.user.gold:
|
||||
<div class="spacer">
|
||||
<%utils:round_field title="${_('options')}" css_class="gold-accent">
|
||||
<input class="nomargin" type="checkbox" checked="checked" name="sendreplies" id="sendreplies" data-send-checked="true"/>
|
||||
<label for="sendreplies">
|
||||
${_("send replies to my inbox")}
|
||||
</label>
|
||||
 <span class="little gray">(${_("beta")})</span>
|
||||
</%utils:round_field>
|
||||
</div>
|
||||
%endif
|
||||
|
||||
${thing.captcha}
|
||||
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user