This commit is contained in:
Albert Yi
2018-06-14 17:10:07 -07:00
parent 65cc1def92
commit b561a6d9ab
2 changed files with 13 additions and 1 deletions

View File

@@ -161,6 +161,18 @@ class Post < ApplicationRecord
storage_manager.file_url(self, :preview)
end
def file_path
storage_manager.file_path(md5, file_ext, :original)
end
def large_file_path
storage_manager.file_path(md5, file_ext, :large)
end
def preview_file_path
storage_manager.file_path(md5, file_ext, :preview)
end
def open_graph_image_url
if is_image?
if has_large?