From 155b60f8b28ed4ed0c5ebe028d7c11480a16318c Mon Sep 17 00:00:00 2001 From: nilsding Date: Sun, 30 Nov 2014 16:09:39 +0100 Subject: [PATCH] "answered by xyz" should not be shown on the user page --- app/views/shared/_answerbox.html.haml | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/app/views/shared/_answerbox.html.haml b/app/views/shared/_answerbox.html.haml index 07ee32a9..f558aa0e 100644 --- a/app/views/shared/_answerbox.html.haml +++ b/app/views/shared/_answerbox.html.haml @@ -9,11 +9,12 @@ %p.answerbox-question-text= a.question.content .panel-body %p= a.content - %p.text-muted - Answered by - %a{href: show_user_profile_path(a.user.screen_name)} - %img.img-rounded.img-answerbox-small{src: gravatar_url(a.user)} - %span= a.user.screen_name + - if @user.nil? + %p.text-muted + Answered by + %a{href: show_user_profile_path(a.user.screen_name)} + %img.img-rounded.img-answerbox-small{src: gravatar_url(a.user)} + %span= a.user.screen_name - if privileged? a.user - %button.btn.btn-danger{name: 'ab-destroy', 'data-a-id' => a.id} + %button.btn.btn-sm.btn-danger{name: 'ab-destroy', 'data-a-id' => a.id} Delete \ No newline at end of file