correct op suppression logic
This commit is contained in:
parent
b662143cae
commit
b3aee62ffe
|
@ -49,9 +49,9 @@ export default {
|
||||||
var canAccept = this.get('post.can_accept_answer');
|
var canAccept = this.get('post.can_accept_answer');
|
||||||
var canUnaccept = this.get('post.can_unaccept_answer');
|
var canUnaccept = this.get('post.can_unaccept_answer');
|
||||||
var accepted = this.get('post.accepted_answer');
|
var accepted = this.get('post.accepted_answer');
|
||||||
var isOp = Discourse.User.currentProp("id") !== this.get('post.topic.user_id');
|
var isOp = Discourse.User.currentProp("id") === this.get('post.topic.user_id');
|
||||||
|
|
||||||
if (canAccept && !isOp) {
|
if (!accepted && canAccept && !isOp) {
|
||||||
// first hidden position
|
// first hidden position
|
||||||
if (this.get('collapsed')) { return; }
|
if (this.get('collapsed')) { return; }
|
||||||
position = visibleButtons.length - 2;
|
position = visibleButtons.length - 2;
|
||||||
|
|
Loading…
Reference in New Issue