diff --git a/app/helpers/application_helper.rb b/app/helpers/application_helper.rb
index 1033d0420..9785c46cf 100644
--- a/app/helpers/application_helper.rb
+++ b/app/helpers/application_helper.rb
@@ -55,10 +55,6 @@ module ApplicationHelper
SiteCustomization::ContentBlock.block_for(name, locale)
end
- def kaminari_path(url)
- "#{root_url.chomp("\/")}#{url}"
- end
-
def self.asset_data_base64(path)
asset = (Rails.application.assets || ::Sprockets::Railtie.build_environment(Rails.application))
.find_asset(path)
diff --git a/app/views/kaminari/_first_page.html.erb b/app/views/kaminari/_first_page.html.erb
index a5335a30b..c97a20740 100644
--- a/app/views/kaminari/_first_page.html.erb
+++ b/app/views/kaminari/_first_page.html.erb
@@ -1,3 +1,3 @@
- <%= link_to t("views.pagination.first"), kaminari_path(url), :remote => remote %>
+ <%= link_to t("views.pagination.first"), url, :remote => remote %>
diff --git a/app/views/kaminari/_last_page.html.erb b/app/views/kaminari/_last_page.html.erb
index 697b3bd15..cc2929aa0 100644
--- a/app/views/kaminari/_last_page.html.erb
+++ b/app/views/kaminari/_last_page.html.erb
@@ -1,3 +1,3 @@
- <%= link_to t("views.pagination.last"), kaminari_path(url), :remote => remote %>
+ <%= link_to t("views.pagination.last"), url, :remote => remote %>
diff --git a/app/views/kaminari/_next_page.html.erb b/app/views/kaminari/_next_page.html.erb
index 366367031..6da585a67 100644
--- a/app/views/kaminari/_next_page.html.erb
+++ b/app/views/kaminari/_next_page.html.erb
@@ -1,3 +1,3 @@
diff --git a/app/views/kaminari/_page.html.erb b/app/views/kaminari/_page.html.erb
index 5d9e7a0d8..c82b8968c 100644
--- a/app/views/kaminari/_page.html.erb
+++ b/app/views/kaminari/_page.html.erb
@@ -5,6 +5,6 @@
<% else %>
- <%= link_to page, kaminari_path(url), { :remote => remote, :rel => page.next? ? "next" : page.prev? ? "prev" : nil } %>
+ <%= link_to page, url, { :remote => remote, :rel => page.next? ? "next" : page.prev? ? "prev" : nil } %>
<% end %>
diff --git a/app/views/kaminari/_prev_page.html.erb b/app/views/kaminari/_prev_page.html.erb
index d0147ff5c..2ee045967 100644
--- a/app/views/kaminari/_prev_page.html.erb
+++ b/app/views/kaminari/_prev_page.html.erb
@@ -1,3 +1,3 @@
diff --git a/spec/features/admin/site_customization/documents_spec.rb b/spec/features/admin/site_customization/documents_spec.rb
index 92f322fac..3d13b30b8 100644
--- a/spec/features/admin/site_customization/documents_spec.rb
+++ b/spec/features/admin/site_customization/documents_spec.rb
@@ -47,7 +47,7 @@ describe "Documents" do
within("ul.pagination") do
expect(page).to have_content("1")
- expect(page).to have_link("2", href: admin_site_customization_documents_url(page: 2))
+ expect(page).to have_link("2", href: admin_site_customization_documents_path(page: 2))
expect(page).not_to have_content("3")
click_link "Next", exact: false
end
diff --git a/spec/features/proposals_spec.rb b/spec/features/proposals_spec.rb
index b4b6e0cfa..a048f7c3c 100644
--- a/spec/features/proposals_spec.rb
+++ b/spec/features/proposals_spec.rb
@@ -103,7 +103,7 @@ describe "Proposals" do
within("ul.pagination") do
expect(page).to have_content("1")
- expect(page).to have_link("2", href: "http://www.example.com/proposals?page=2")
+ expect(page).to have_link("2", href: "/proposals?page=2")
expect(page).not_to have_content("3")
click_link "Next", exact: false
end