about summary refs log tree commit diff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/mastodon/premailer_webpack_strategy.rb3
-rw-r--r--lib/mastodon/version.rb6
-rw-r--r--lib/tasks/mastodon.rake9
3 files changed, 15 insertions, 3 deletions
diff --git a/lib/mastodon/premailer_webpack_strategy.rb b/lib/mastodon/premailer_webpack_strategy.rb
index 4ea3ce80c..84d83cc66 100644
--- a/lib/mastodon/premailer_webpack_strategy.rb
+++ b/lib/mastodon/premailer_webpack_strategy.rb
@@ -2,6 +2,9 @@
 
 module PremailerWebpackStrategy
   def load(url)
+    public_path_host = ENV['ASSET_HOST'] || ENV['LOCAL_DOMAIN']
+    url = url.gsub(/\A\/\/#{public_path_host}/, '')
+
     if Webpacker.dev_server.running?
       url = File.join("#{Webpacker.dev_server.protocol}://#{Webpacker.dev_server.host_with_port}", url)
       HTTP.get(url).to_s
diff --git a/lib/mastodon/version.rb b/lib/mastodon/version.rb
index 5936b5fcf..098ab46ac 100644
--- a/lib/mastodon/version.rb
+++ b/lib/mastodon/version.rb
@@ -9,11 +9,11 @@ module Mastodon
     end
 
     def minor
-      1
+      2
     end
 
     def patch
-      3
+      0
     end
 
     def pre
@@ -21,7 +21,7 @@ module Mastodon
     end
 
     def flags
-      ''
+      'rc1'
     end
 
     def to_a
diff --git a/lib/tasks/mastodon.rake b/lib/tasks/mastodon.rake
index 38dbed982..486c035de 100644
--- a/lib/tasks/mastodon.rake
+++ b/lib/tasks/mastodon.rake
@@ -341,6 +341,15 @@ namespace :mastodon do
       LinkCrawlWorker.push_bulk status_ids
     end
 
+    desc 'Remove all home feed regeneration markers'
+    task remove_regeneration_markers: :environment do
+      keys = Redis.current.keys('account:*:regeneration')
+
+      Redis.current.pipelined do
+        keys.each { |key| Redis.current.del(key) }
+      end
+    end
+
     desc 'Check every known remote account and delete those that no longer exist in origin'
     task purge_removed_accounts: :environment do
       prepare_for_options!