mirror of
https://github.com/codeninjasllc/discourse.git
synced 2025-02-16 03:30:05 -05:00
17 lines
339 B
Ruby
17 lines
339 B
Ruby
|
class ExportCsv
|
||
|
|
||
|
def self.get_download_path(filename)
|
||
|
path = File.join(ExportCsv.base_directory, filename)
|
||
|
if File.exists?(path)
|
||
|
return path
|
||
|
else
|
||
|
nil
|
||
|
end
|
||
|
end
|
||
|
|
||
|
def self.base_directory
|
||
|
File.join(Rails.root, "public", "uploads", "csv_exports", RailsMultisite::ConnectionManagement.current_db)
|
||
|
end
|
||
|
|
||
|
end
|