From 209903f35db79edee6dd2f16050ac5848931e816 Mon Sep 17 00:00:00 2001 From: chiu Date: Thu, 9 Sep 2021 06:35:19 +0000 Subject: [PATCH] fix error --- app/controllers/archives_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/archives_controller.rb b/app/controllers/archives_controller.rb index 3c67362..ad7a7f8 100644 --- a/app/controllers/archives_controller.rb +++ b/app/controllers/archives_controller.rb @@ -16,6 +16,7 @@ class ArchivesController < ApplicationController end def index params = OrbitHelper.params + @@total_pages = 1 if !params['title'].nil? files_by_category = ArchiveFile.where(is_hidden: false).order_by(:created_at => "desc").group_by(&:category) categories = files_by_category.keys @@ -74,7 +75,6 @@ class ArchivesController < ApplicationController } end end - @@total_pages = 1 else if OrbitHelper.page_data_count > 0 OrbitHelper.set_page_data_count 0 @@ -387,4 +387,4 @@ class ArchivesController < ApplicationController def self.get_total_pages @@total_pages end -end \ No newline at end of file +end