Skip to content
This repository has been archived by the owner on Jun 29, 2024. It is now read-only.

Removal of "Legacy" group breaks old posts #291

Closed
lindskogen opened this issue Aug 8, 2017 · 2 comments
Closed

Removal of "Legacy" group breaks old posts #291

lindskogen opened this issue Aug 8, 2017 · 2 comments
Labels

Comments

@lindskogen
Copy link
Contributor

See for example posts made by Horv: https://chalmers.it/posts?user=johandf

F, [2017-08-08T20:37:41.443207 #15647] FATAL -- :
ActionView::Template::Error (undefined method `name' for nil:NilClass):
    11:         <%= link_to post.comments.size, post_path(post, anchor: 'comments'), title: "#{post.comments.size} #{Comment.model_name.human(count:post.comments.size).downcase}", class: 'comments-bubble smooth', data: { tooltip: '' } %>
    12:         <span class="sep">|</span> <time data-tooltip title="<%= t 'published' %> <%= post.created_at.to_s(:iso_date_time) %>" datetime="<%= post.created_at.to_s(:rfc822) %>" pubdate itemprop="datePublished"><%= post.created_at.to_s(:day_month) %></time>
    13:         <span class="sep">|</span> <%= link_to t('permalink'), post %>
    14:         <span class="sep">|</span>  <%= t '.posted_for' %> <%= link_to_committee post %> <%= t '.by' %> <%= link_to post.user.display_name, posts_path(user: post.user), title: "#{t '.posts_by'} #{post.user.display_name}", rel: 'author' %>
    15:         <% if policy(post).update? %>
    16:           <span class="sep">|</span> <%= link_to t('helpers.submit.update', model: Post.model_name.human.downcase), edit_post_path(post) %>
    17:         <% end %>
  app/helpers/posts_helper.rb:29:in `link_to_committee'
  app/views/posts/_post.html.erb:14:in `_app_views_posts__post_html_erb___1868493670942335549_47075385907180'
  app/views/posts/index.html.erb:3:in `_app_views_posts_index_html_erb___2110157584837852064_47075382429800'

This is because the group with id=legacy does not exist

@lindskogen lindskogen added the bug label Aug 8, 2017
@williamleven
Copy link
Member

The group with id=legacy has been been created again and the error does no longer appear.
Do however keep this issue open as the legacy should be removed in some manner.

@malmers
Copy link
Member

malmers commented Sep 5, 2017

Opened #309 as the legacy committee has been reintroduced

@malmers malmers closed this as completed Sep 5, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

3 participants