diff --git a/app/models/stash_api/dataset_parser.rb b/app/models/stash_api/dataset_parser.rb index bfd0e0d16..a4cabaa94 100644 --- a/app/models/stash_api/dataset_parser.rb +++ b/app/models/stash_api/dataset_parser.rb @@ -69,7 +69,7 @@ def send_submit_invitation_email(metadata) def resource_uniq? return true if @id - query = StashEngine::Resource.joins(:user).where( + query = StashEngine::Resource.joins(:users).where( stash_engine_resources: { title: @hash[:title] }, stash_engine_users: { orcid: @user.orcid } )