diff --git a/Changelog.md b/Changelog.md index a23aeaba1..078b62bbe 100644 --- a/Changelog.md +++ b/Changelog.md @@ -155,6 +155,8 @@ before. ## Refactor +* Removed the publisher from a user's photo stream due to various issues [#6851](https://github.com/diaspora/diaspora/pull/6851) + ## Bug fixes ## Features diff --git a/app/assets/javascripts/app/pages/profile.js b/app/assets/javascripts/app/pages/profile.js index 3d707370f..90ea5ed87 100644 --- a/app/assets/javascripts/app/pages/profile.js +++ b/app/assets/javascripts/app/pages/profile.js @@ -86,7 +86,7 @@ app.pages.Profile = app.views.Base.extend({ }); app.stream.fetch(); - if( this.model.get("is_own_profile") ) { + if( this.model.get("is_own_profile") && route !== "personPhotos" ) { app.publisher = new app.views.Publisher({collection : app.stream.items}); } app.shortcuts = app.shortcuts || new app.views.StreamShortcuts({el: $(document)}); diff --git a/app/views/people/show.html.haml b/app/views/people/show.html.haml index 3f4ad5bbd..982f7c536 100644 --- a/app/views/people/show.html.haml +++ b/app/views/people/show.html.haml @@ -17,7 +17,7 @@ .stream_container - - if user_signed_in? && current_user.person.id == @person.id + - if user_signed_in? && current_user.person.id == @person.id && !current_page?(person_photos_path(@person)) = render 'publisher/publisher', publisher_aspects_for(nil) .stream.clearfix#main_stream diff --git a/spec/integration/profile_spec.rb b/spec/integration/profile_spec.rb index 4884e530a..3c6a20793 100644 --- a/spec/integration/profile_spec.rb +++ b/spec/integration/profile_spec.rb @@ -24,6 +24,15 @@ describe PeopleController, type: :request do expect(response.body).not_to match(/a class="login"/) expect(response.body).to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/) end + + it "doesn't display the publisher for people photos path" do + get "/people/#{alice.person.guid}/photos" + + expect(response.status).to eq(200) + # make sure we are signed in + expect(response.body).not_to match(/a class="login"/) + expect(response.body).not_to match(/div class='publisher-textarea-wrapper' id='publisher_textarea_wrapper'/) + end end context "for another user" do