Skip to content

Commit 172fd3f

Browse files
authored
Merge pull request #102 from phillmv/fix-asset-paths-given-users
fix broken file uploads when ARQUIVO_USER is specificed
2 parents cd27cd7 + a0638b0 commit 172fd3f

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

config/environments/development.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
config.hosts << "arquivo.io"
1111

1212
# until we figure out how to multitenant this,
13-
config.active_storage.routes_prefix = ENV["ARQUIVO_USER"] || "/phillmv/_"
13+
config.active_storage.routes_prefix = "#{ENV['ARQUIVO_USER']}/_" || "/phillmv/_"
1414

1515
# Settings specified here will take precedence over those in config/application.rb.
1616

config/environments/production.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
end
99

1010
# until we figure out how to multitenant this,
11-
config.active_storage.routes_prefix = ENV["ARQUIVO_USER"] || "/phillmv/_"
11+
config.active_storage.routes_prefix = "#{ENV['ARQUIVO_USER']}/_" || "/phillmv/_"
1212
# config.active_storage.routes_prefix = "/#{User.current}/_"
1313
# config.assets.prefix = "/#{User.current}/_"
1414

0 commit comments

Comments
 (0)