mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-12-31 04:32:06 +08:00
Merge pull request #7627 from aignatov-bio/ai-sci-10767-add-filename-to-asset-version-token
Add filename to asset token [SCI-10767]
This commit is contained in:
commit
9ed9b76883
1 changed files with 1 additions and 1 deletions
|
@ -10,7 +10,7 @@ class AssetSyncToken < ApplicationRecord
|
|||
validates :token, uniqueness: true, presence: true
|
||||
|
||||
def version_token
|
||||
asset.file.checksum
|
||||
OpenSSL::Digest::SHA256.base64digest(asset.file.checksum + asset.file_name)
|
||||
end
|
||||
|
||||
def token_valid?
|
||||
|
|
Loading…
Reference in a new issue