mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-02-24 15:54:00 +08:00
Merge pull request #2119 from aignatov-bio/ai-sci-fix-marvin-js-preview
Fix marvin JS preview
This commit is contained in:
commit
afecc3fd0e
1 changed files with 1 additions and 2 deletions
|
@ -18,8 +18,7 @@ class AssetsController < ApplicationController
|
|||
before_action :check_edit_permission, only: :edit
|
||||
|
||||
def file_preview
|
||||
file_type = 'previewable' if @asset.previewable?
|
||||
file_type ||= @asset.file.metadata[:asset_type]
|
||||
file_type = @asset.file.metadata[:asset_type] || (@asset.previewable? ? 'previewable' : false)
|
||||
response_json = {
|
||||
'id' => @asset.id,
|
||||
'type' => file_type,
|
||||
|
|
Loading…
Reference in a new issue