]> cat aescling's git repositories - mastodon.git/commitdiff
Merge branch 'master' into glitch-soc/merge-upstream
authorThibaut Girka <thib@sitedethib.com>
Fri, 7 Jun 2019 15:00:36 +0000 (17:00 +0200)
committerThibaut Girka <thib@sitedethib.com>
Fri, 7 Jun 2019 15:00:36 +0000 (17:00 +0200)
Conflicts:
- app/controllers/statuses_controller.rb
- app/controllers/stream_entries_controller.rb

19 files changed:
1  2 
Gemfile
Gemfile.lock
app/controllers/accounts_controller.rb
app/controllers/application_controller.rb
app/controllers/follower_accounts_controller.rb
app/controllers/following_accounts_controller.rb
app/controllers/statuses_controller.rb
app/controllers/stream_entries_controller.rb
app/javascript/mastodon/features/compose/components/compose_form.js
app/javascript/styles/mastodon/admin.scss
app/javascript/styles/mastodon/components.scss
app/models/account.rb
app/models/status.rb
app/services/process_mentions_service.rb
app/services/reblog_service.rb
app/services/remove_status_service.rb
app/workers/activitypub/distribute_poll_update_worker.rb
config/locales/en.yml
package.json

diff --cc Gemfile
Simple merge
diff --cc Gemfile.lock
Simple merge
index 28eebda28b39fadfc199193ea901ee731bb88317,ef26691b296c34895b76cb8ea63297428ae1fc20..66ba260aada2408f8f84fbd02fef52938ef589be
@@@ -27,12 -27,7 +27,9 @@@ class StatusesController < ApplicationC
    def show
      respond_to do |format|
        format.html do
-         unless user_signed_in?
-           skip_session!
-           expires_in 10.seconds, public: true
-         end
 +        use_pack 'public'
 +
+         expires_in 10.seconds, public: true if current_account.nil?
  
          @body_classes = 'with-modals'
  
    end
  
    def embed
 +    use_pack 'embed'
      raise ActiveRecord::RecordNotFound if @status.hidden?
  
-     skip_session!
      expires_in 180, public: true
      response.headers['X-Frame-Options'] = 'ALLOWALL'
      @autoplay = ActiveModel::Type::Boolean.new.cast(params[:autoplay])
index 1e16c5157d73fa9c110b9249f8cd6376ff7668fb,0f7e9e0f569f174aa2593e7cefcde987789a7803..1ee85592c73f9def90639022fdda8f85e9601c09
@@@ -15,14 -15,9 +15,11 @@@ class StreamEntriesController < Applica
    def show
      respond_to do |format|
        format.html do
-         unless user_signed_in?
-           skip_session!
-           expires_in 5.minutes, public: true
-         end
 +        use_pack 'public'
 +
+         expires_in 5.minutes, public: true unless @stream_entry.hidden?
  
-         redirect_to short_account_status_url(params[:account_username], @stream_entry.activity) if @type == 'status'
+         redirect_to short_account_status_url(params[:account_username], @stream_entry.activity)
        end
  
        format.atom do
  
    def set_stream_entry
      @stream_entry = @account.stream_entries.where(activity_type: 'Status').find(params[:id])
-     @type         = @stream_entry.activity_type.downcase
+     @type         = 'status'
  
      raise ActiveRecord::RecordNotFound if @stream_entry.activity.nil?
 -    authorize @stream_entry.activity, :show? if @stream_entry.hidden?
 +    authorize @stream_entry.activity, :show? if @stream_entry.hidden? || @stream_entry.local_only?
    rescue Mastodon::NotPermittedError
      # Reraise in order to get a 404
      raise ActiveRecord::RecordNotFound
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc package.json
Simple merge