From f7c58f6a77741e3671e435c7d9c871d565d0dd1a Mon Sep 17 00:00:00 2001 From: George Vinogradov Date: Mon, 30 Jan 2012 13:12:18 +0400 Subject: [PATCH] [issue #64] Removed unnecessary files. --- app/controllers/wiki_controller.rb | 2 +- app/views/wiki/index.html.haml | 0 lib/gollum.rb | 27 --------------------------- 3 files changed, 1 insertion(+), 28 deletions(-) delete mode 100644 app/views/wiki/index.html.haml delete mode 100644 lib/gollum.rb diff --git a/app/controllers/wiki_controller.rb b/app/controllers/wiki_controller.rb index 47cddcbda..cd3159a18 100644 --- a/app/controllers/wiki_controller.rb +++ b/app/controllers/wiki_controller.rb @@ -1,4 +1,4 @@ -require 'lib/gollum' +#require 'lib/gollum' require 'cgi' class WikiController < ApplicationController diff --git a/app/views/wiki/index.html.haml b/app/views/wiki/index.html.haml deleted file mode 100644 index e69de29bb..000000000 diff --git a/lib/gollum.rb b/lib/gollum.rb deleted file mode 100644 index b5b1a20f4..000000000 --- a/lib/gollum.rb +++ /dev/null @@ -1,27 +0,0 @@ -module Gollum - class PaginateableArray < Array - require 'will_paginate/collection' - - def paginate(options = {}) - page = options[:page] || 1 - per_page = options[:per_page] || WillPaginate.per_page - total = options[:total_entries] || self.length - - WillPaginate::Collection.create(page, per_page, total) do |pager| - pager.replace self[pager.offset, pager.per_page].to_a - end - end - end - - class PageImproved < Page - - def versions(options = {}) - options.delete :page - options.delete :per_page - puts super(options) - - res = PaginateableArray.new(super(options)) - puts res.inspect - end - end -end