always sort by created_at on mobile
This commit is contained in:
parent
8c586c4567
commit
ab3d220b57
1 changed files with 5 additions and 1 deletions
|
|
@ -17,7 +17,7 @@ class AspectsController < ApplicationController
|
||||||
def index
|
def index
|
||||||
aspect_ids = (params[:a_ids] ? params[:a_ids] : [])
|
aspect_ids = (params[:a_ids] ? params[:a_ids] : [])
|
||||||
@stream = AspectStream.new(current_user, aspect_ids,
|
@stream = AspectStream.new(current_user, aspect_ids,
|
||||||
:order => session[:sort_order],
|
:order => sort_order,
|
||||||
:max_time => params[:max_time].to_i)
|
:max_time => params[:max_time].to_i)
|
||||||
|
|
||||||
if params[:only_posts]
|
if params[:only_posts]
|
||||||
|
|
@ -148,4 +148,8 @@ class AspectsController < ApplicationController
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def sort_order
|
||||||
|
is_mobile_device? ? 'created_at' : session[:sort_order]
|
||||||
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue