   constructor: ->
     super
     @showing = 'recents'
+    @opts =
+      per_page: 12
     User.bind 'sign-in', @refresh
   
   collection: =>

  
  refresh: =>
    if User.current
      fetcher = @collection().fetch()
      fetcher.onSuccess(@render) if @isActive()
  
  active: ->

    item = @collection().find $(e.target).closest('.item').data 'id'
    item.favorite().onSuccess @render
  
  switch: ({ originalEvent: e }) =>
    toShow = $(e.target).closest('a').data 'show'
    return if toShow is @showing
    @showing = toShow
    @collection().fetch(@opts).onSuccess @render

module.exports = Profile
