mirror of
https://github.com/reddit-archive/reddit.git
synced 2026-01-29 00:38:11 -05:00
Add auto description attribution to copied multireddits.
This commit is contained in:
@@ -217,6 +217,7 @@ Note: there are a couple of places outside of your subreddit where someone can c
|
||||
awesomeness_goes_here = _('awesomeness goes here'),
|
||||
add_multi_sr = _('add a subreddit to your multi.'),
|
||||
open_multi = _('open this multi'),
|
||||
copied_from = _('copied from %(source)s'),
|
||||
)
|
||||
|
||||
class StringHandler(object):
|
||||
|
||||
@@ -148,6 +148,10 @@ r.multi.MultiReddit = Backbone.Model.extend({
|
||||
var attrs = _.clone(this.attributes)
|
||||
delete attrs.path
|
||||
attrs.visibility = 'private'
|
||||
attrs.description_md = this.get('description_md') + '\n\n' + r.strings('copied_from', {
|
||||
// ensure that linking happens (currently /user/foo is not autolinked)
|
||||
source: '[' + this.get('path') + '](' + this.get('path') + ')'
|
||||
})
|
||||
newMulti.set(attrs)
|
||||
return newMulti
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user