diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-06-30 15:34:16 +0200 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-06-30 15:34:16 +0200 |
commit | b76659c5378fbcb61ecefa0db55830465e152d30 (patch) | |
tree | d1fea5291cd036e4133683c0e49483dde7679403 /app/views/events | |
parent | 16c71a3bab31ab909200fc319f04084e3931e04e (diff) | |
download | gitlab-ce-b76659c5378fbcb61ecefa0db55830465e152d30.tar.gz |
Re-use event cache with other users unless its personal
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/views/events')
-rw-r--r-- | app/views/events/_event.html.haml | 21 |
1 files changed, 11 insertions, 10 deletions
diff --git a/app/views/events/_event.html.haml b/app/views/events/_event.html.haml index 02b1dec753c..b2e5d11279b 100644 --- a/app/views/events/_event.html.haml +++ b/app/views/events/_event.html.haml @@ -3,14 +3,15 @@ .event-item-timestamp #{time_ago_with_tooltip(event.created_at)} - = cache [event, current_user] do - = image_tag avatar_icon(event.author_email, 24), class: "avatar s24", alt:'' - - - if event.push? - = render "events/event/push", event: event - - elsif event.commented? - = render "events/event/note", event: event - - elsif event.created_project? + - if event.created_project? + = cache [event, current_user] do = render "events/event/created_project", event: event - - else - = render "events/event/common", event: event
\ No newline at end of file + - else + = cache event do + = image_tag avatar_icon(event.author_email, 24), class: "avatar s24", alt:'' + - if event.push? + = render "events/event/push", event: event + - elsif event.commented? + = render "events/event/note", event: event + - else + = render "events/event/common", event: event |