FIX: Fix the shortcut shift+p for pinning/unpinning a topic
This commit is contained in:
parent
35496cae4f
commit
d2502bd127
|
@ -374,10 +374,11 @@ export default Ember.Controller.extend(SelectedPostsCount, BufferedContent, {
|
||||||
|
|
||||||
togglePinnedForUser() {
|
togglePinnedForUser() {
|
||||||
if (this.get('model.pinned_at')) {
|
if (this.get('model.pinned_at')) {
|
||||||
if (this.get('pinned')) {
|
const topic = this.get('content');
|
||||||
this.get('content').clearPin();
|
if (topic.get('pinned')) {
|
||||||
|
topic.clearPin();
|
||||||
} else {
|
} else {
|
||||||
this.get('content').rePin();
|
topic.rePin();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue