def create
			@post = Post.new(post_params)
			@post.author = current_author

			authorize @post

			# Save here before potentially publishing, so we can save images
			if @post.save

				if params[:publish] == "true"
					@post.publish
					authorize @post # Re-authorize now that it's to be published
				end

				# Save and rewrite each image in Carrierwave's cache
				@post.body = saved_and_rewrite_cached_images(@post.body)

				# Save again, in case the body changed or it was published
				@post.save

				redirect_to @post, notice: 'Post was successfully created.'
			else
				render :new
			end
		end
def create
			@post = Post.new(post_params)
			@post.author = current_author

			authorize @post

			# Save here before potentially publishing, so we can save images
			if @post.save

				if params[:publish] == "true"
					@post.publish
					authorize @post # Re-authorize now that it's to be published
				end

				# Save and rewrite each image in Carrierwave's cache
				@post.body = saved_and_rewrite_cached_images(@post.body)

				# Save again, in case the body changed or it was published
				@post.save

				redirect_to @post, notice: 'Post was successfully created.'
			else
				render :new
			end
		end
POST /posts