mirror of
https://github.com/ryankazokas/turbovault-app.git
synced 2026-04-16 23:22:53 +00:00
Moving to github
This commit is contained in:
7
app/models/collection_game.rb
Normal file
7
app/models/collection_game.rb
Normal file
@@ -0,0 +1,7 @@
|
||||
class CollectionGame < ApplicationRecord
|
||||
belongs_to :collection
|
||||
belongs_to :game
|
||||
|
||||
# Validations
|
||||
validates :game_id, uniqueness: { scope: :collection_id, message: "already in this collection" }
|
||||
end
|
||||
Reference in New Issue
Block a user