Redirect to stream_path if is destkop
This commit is contained in:
parent
682a49605e
commit
2311b761e1
2 changed files with 9 additions and 2 deletions
|
|
@ -29,11 +29,13 @@ class StatusMessagesController < ApplicationController
|
|||
@contacts_of_contact = @contact.contacts
|
||||
render :layout => nil
|
||||
end
|
||||
else
|
||||
elsif(request.format == :mobile)
|
||||
@aspect = :all
|
||||
@aspects = current_user.aspects
|
||||
@aspect_ids = @aspects.map{ |a| a.id }
|
||||
gon.aspect_ids = @aspect_ids
|
||||
else
|
||||
redirect_to stream_path
|
||||
end
|
||||
end
|
||||
|
||||
|
|
@ -125,4 +127,4 @@ class StatusMessagesController < ApplicationController
|
|||
def remove_getting_started
|
||||
current_user.disable_getting_started
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -58,6 +58,11 @@ describe StatusMessagesController do
|
|||
response.should be_success
|
||||
end
|
||||
|
||||
it 'should redirect on desktop version' do
|
||||
get :new
|
||||
response.should redirect_to(stream_path)
|
||||
end
|
||||
|
||||
it 'generates a jasmine fixture', :fixture => true do
|
||||
contact = alice.contact_for(bob.person)
|
||||
aspect = alice.aspects.create(:name => 'people')
|
||||
|
|
|
|||
Loading…
Reference in a new issue