Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions app/controllers/chapters_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,7 @@ def update
render :preview
else
@chapter.posted = true if params[:post_button] || params[:post_without_preview_button]
@work.posted = true if @chapter.posted?
posted_changed = @chapter.posted_changed?
@work.set_revised_at_by_chapter(@chapter)
if @chapter.save && @work.save
Expand Down
1 change: 0 additions & 1 deletion spec/controllers/chapters_controller_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -783,7 +783,6 @@
end

it "posts the work if the work was not posted before" do
pending "multi-chapter works should post when chapter is posted"
put :update, params: { work_id: unposted_work.id, id: unposted_work.chapters.first.id, chapter: chapter_attributes, post_button: true }
expect(assigns[:work].posted).to be true
end
Expand Down
Loading