Skip to content

Commit 69b42c6

Browse files
author
Matt Swanson
committed
remove story author, unneeded and causing headaches
1 parent 8096bf2 commit 69b42c6

5 files changed

Lines changed: 9 additions & 5 deletions

File tree

‎app/public/css/styles.css‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ li.story.open .story-preview {
146146
color: #e5e5e5;
147147
}
148148

149-
.story-author {
149+
.story-published {
150150
margin-left: 20px;
151151
}
152152

‎app/repositories/story_repository.rb‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ def self.add(entry, feed)
55
Story.create(feed: feed,
66
title: entry.title,
77
permalink: entry.url,
8-
author: entry.author || feed.author,
98
body: StoryRepository.extract_content(entry),
109
is_read: false,
1110
published: entry.published || Time.now)

‎app/tasks/fetch_feed.rb‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def initialize(feed, feed_parser = Feedzirra::Feed)
1414
def fetch
1515
begin
1616
raw_feed = @parser.fetch_and_parse(@feed.url)
17-
17+
1818
new_entries_from(raw_feed).each do |entry|
1919
StoryRepository.add(entry, @feed)
2020
end

‎app/views/partials/_story.erb‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@
2424
</div>
2525
<div class="row-fluid story-actions-container">
2626
<div class="pull-left">
27-
<span class="story-author">
28-
<%= story.author %> &mdash; <%= story.published.strftime("%A, %B %d") %>
27+
<span class="story-published">
28+
<%= story.published.strftime("%A, %B %d") %>
2929
</span>
3030
</div>
3131
<div class="pull-right story-actions">
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
class RemoveAuthorFromStories < ActiveRecord::Migration
2+
def change
3+
remove_column :stories, :author
4+
end
5+
end

0 commit comments

Comments
 (0)