Commit 38163cc8

mo khan <mo@mokhan.ca>
2014-10-19 03:22:56
extract method to search for artists.
1 parent 2a48ce4
Changed files (2)
app
app/controllers/profiles_controller.rb
@@ -5,7 +5,7 @@ class ProfilesController < ApplicationController
   end
 
   def index
-    @profiles = repository.artists.page(params[:page]).per(12)
+    @profiles = repository.search_with(params).page(params[:page]).per(12)
   end
 
   def show
app/models/user/repository.rb
@@ -16,6 +16,10 @@ class User
       connection.includes(:avatar).artists
     end
 
+    def search_with(params)
+      artists
+    end
+
     private
 
     attr_reader :connection